
ikegami at adaelis
May 3, 2012, 12:32 AM
Post #3 of 3
(47 views)
Permalink
|
|
Re: [perl #63476] Cannot find current script '/dev/null' at /usr/share/perl/5.10/FindBin.pm line 206
[In reply to]
|
|
On Tue, May 1, 2012 at 9:52 PM, James E Keenan via RT < perlbug-followup [at] perl> wrote: > Discussion in this thread petered out three years ago. Jesse seems to > be saying that this is not a bug in FindBin. Should we keep this ticket > open? > ModPerl::Registry does set $0, so FindBin should work fine from registry scripts (though you'll need to call C<< FindBin::again() >> as per the documentation). I presume this problem occurs if he tries to load FindBin from the startup script or equivalent, in which case it falls to mod_perl to provide something useful in $0. Even if I'm missing something, I don't see how this can possibly be a problem with FindBin. Closing this ticket. - Eric Mod::PerlRegistry's wrapper: my $eval = join '', 'package ', $self->{PACKAGE}, ";", "sub handler {", "local \$0 = '$script_name';", $nph, $shebang, $line, ${ $self->{CODE} }, "\n}"; # last line comment without newline?
|