On Mon, Aug 19, 2002 at 08:39:11AM +0200, Gerald Richter wrote: > Hi > > with perl 5.8/ apache 2.0.40 / mod_perl 1.99_05 / DBI 1.30 > > "use DBI " > > in the startup.pl (before child cloning process) script makes apache > > segfault in pel 58.dll this is on win32 > > I have the same behaviour here. The problem is the dup of the trace > filehandle. Perl's dup function accesses a table (PL_ptr_table) which isn't > intialized at the time dup is called when the Perl interpreters gets cloned > under mod_perl. > > The following change fixes that, but now the trace filehandle is not cloned > anymore. That means you have to set the trace file in every thread and > cannot set it in the parent thread. > > DBI.xs line 223 change from > > DBIS->logfp = parent_dbis ? fp_dup(parent_dbis->logfp,'>',0) : PerlIO_stderr(); > to > DBIS->logfp = parent_dbis && PL_ptr_table ? fp_dup(parent_dbis->logfp,'>',0) : >PerlIO_stderr();
I'd appreciate it if some on perl5-porters could give me the "correct" way to dup a PerlIO during a CLONE call. Tim. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
