Work around for perl 5.10 bug - fix due to perl hacker Simon Cozens.
authorAndrew Dunstan <andrew@dunslane.net>
Tue, 22 Jan 2008 20:41:39 +0000 (20:41 +0000)
committerAndrew Dunstan <andrew@dunslane.net>
Tue, 22 Jan 2008 20:41:39 +0000 (20:41 +0000)
src/pl/plperl/plperl.c

index d7b9f89192878cc7ed6228a40cb9ab09d37d41a6..36f9ab74b112f14ca02b1c467be584a3ef79a8b6 100644 (file)
@@ -272,8 +272,8 @@ _PG_init(void)
        "sub ::mksafefunc {" \
        "      my $ret = $PLContainer->reval(qq[sub { $_[0] $_[1] }]); " \
        "      $@ =~ s/\\(eval \\d+\\) //g if $@; return $ret; }" \
-       "$PLContainer->permit('require'); $PLContainer->reval('use strict;');" \
-       "$PLContainer->deny('require');" \
+       "$PLContainer->permit(qw[require caller]); $PLContainer->reval('use strict;');" \
+       "$PLContainer->deny(qw[require caller]); " \
        "sub ::mk_strict_safefunc {" \
        "      my $ret = $PLContainer->reval(qq[sub { BEGIN { strict->import(); } $_[0] $_[1] }]); " \
        "      $@ =~ s/\\(eval \\d+\\) //g if $@; return $ret; }"