Hi,
I moved up to mod_perl cvs snapshot ( should have done this before I posted before as it fixed a header issue I was also having! D'oh! )
'make test' now passes everything except ModPerl-Registry/t/cgi-bin/r_inherited.pl didn't have execution set and thus one test failed ( This could just be my setup??). All tests passed after a chmod.
Great :)
CGI.pm version 3.04 modperl cvs snapshot gcc 3.2.2 Apache : 2.0.49 prefork
This script causes a segfault because of the global cgio object :
use CGI; my $cgio = CGI->new(); send_login();
sub send_login { print $cgio->header(); print "<html><body>hitest1</body></html>"; }
If you pass cgio to send_login no segfault.
It's because you created a closure. Take a look at:
http://perl.apache.org/docs/2.0/user/coding/coding.html#C_ModPerl__Registry__Handlers_Family
On the second request it still tries to use the old object, which is invalid. There is a lot of discussion about this issue at:
http://perl.apache.org/docs/general/perl_reference/perl_reference.html#my___Scoped_Variable_in_Nested_Subroutines
and in other sections of that document.
__________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]