avoid strange FreeBSD problem
<mxey> I have a weird problem with Ikiwiki on FreeBSD: When rendering this page <http://rafb.net/p/zmfROX86.html>, I get "ikiwiki.setup: Modification of a read-only value attempted at /usr/local/lib/perl5/site_perl/5.8.8/IkiWiki.pm line 1300.". And converting the constructors to not operate on the parameters directly but use lexical variables fixed it. Not sure exactly when this occurs.master
parent
ad44c47977
commit
a7b8069b9d
|
@ -1287,7 +1287,9 @@ use overload ( #{{{
|
||||||
); #}}}
|
); #}}}
|
||||||
|
|
||||||
sub new { #{{{
|
sub new { #{{{
|
||||||
return bless \$_[1], $_[0];
|
my $class = shift;
|
||||||
|
my $value = shift;
|
||||||
|
return bless \$value, $class;
|
||||||
} #}}}
|
} #}}}
|
||||||
|
|
||||||
package IkiWiki::SuccessReason;
|
package IkiWiki::SuccessReason;
|
||||||
|
@ -1300,7 +1302,9 @@ use overload ( #{{{
|
||||||
); #}}}
|
); #}}}
|
||||||
|
|
||||||
sub new { #{{{
|
sub new { #{{{
|
||||||
return bless \$_[1], $_[0];
|
my $class = shift;
|
||||||
|
my $value = shift;
|
||||||
|
return bless \$value, $class;
|
||||||
}; #}}}
|
}; #}}}
|
||||||
|
|
||||||
package IkiWiki::PageSpec;
|
package IkiWiki::PageSpec;
|
||||||
|
|
Loading…
Reference in New Issue