Re: [perl #75722] Recursive call to Perl_load_module in PerlIO_find_layer

[email protected] (Nicholas Clark)
Newsgroups perl.perl5.porters
Message-ID <[email protected]>
On Sun, Jun 13, 2010 at 06:29:52PM -0700, Father Chrysostomos wrote:
> # New Ticket Created by  Father Chrysostomos 
> # Please include the string:  [perl #75722]
> # in the subject line of all future correspondence about this issue. 
> # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=75722 >
> 
> 
> $ perl -le' unshift @INC, sub { return undef unless caller eq "main";  
> open my $fh, "<", \1; $fh }; require oaeunt'
> Recursive call to Perl_load_module in PerlIO_find_layer at -e line 1.
> BEGIN failed--compilation aborted.
> 
> This error message is not documented in perldiag.
> 
> Also, as an aside, it would be nice if this limitation could be lifted.

Slaven added this error, and the restriction, in 2002:

http://perl5.git.perl.org/perl.git/commit/d7a09b413c09654b
in response to this bug http://rt.perl.org/rt3/Ticket/Display.html?id=18203

    This will blow your stack:
    
    perl -Mopen=IO,:non-existant -MAnything -e1
    
    A possible solution is to install a recursion watcher. Here is a patch
    against bleedperl:


I'm not sure what form a better fix would take.

Nicholas Clark
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.