Kurt George Gjerde wrote:

>Stas Bekman wrote:
>
>  
>
>>If you can try and fix it that would be great (see Jan's solution). You 
>>should be able to reproduce it outside mod_perl with 'use threads and 
>>starting a thread after using nfreeze'.
>>    
>>
>
>I'm not the right person to try and fix this (lacking both the 
>experience and a C compiler; and it would take me too long to get into 
>XS and all that).
>
I have a C/C++ compiler and some XS knowledge, but I'm out of my depth 
with the threads stuff.  I'm happy to assist in any way I can.

Stas: I looked at Jan's e-mail which you previously cited, but I 
couldn't figure out what I was supposed to do with it.  Do you have a 
patch that I can try out?

>Sorry. But yes, the following two scripts reproduces 
>the error.
>
They both fail for me too.  Only the first one gives the "free to pool 
during global destruction" error, but both give program error popup 
windows.  Stack traces below from 5.8.3-RC1.  (They're both the same, I 
think.)

- Steve

>
>You want me to send this to perl5-porters?
>
>-Kurt.
>
>
>-1-
>   # Perl dies with "free to wrong pool"
>   use threads;
>   use Storable qw(nfreeze);
>
>   my $t = threads->new(\&sub1);
>
>   sleep 1;
>
>   sub sub1 {
>     nfreeze {};
>   }
>
VMem::Free(void * 0x019b1004) line 208 + 3 bytes
CPerlHost::Free(void * 0x019b1004) line 59 + 34 bytes
PerlMemFree(IPerlMem * 0x002224e4, void * 0x019b1004) line 302
Perl_safesysfree(void * 0x019b1004) line 140 + 26 bytes
XS_Storable__Cxt_DESTROY(interpreter * 0x0022411c, cv * 0x018ffc94) line 
5884 + 12 bytes
Perl_pp_entersub(interpreter * 0x0022411c) line 2840 + 16 bytes
S_call_body(interpreter * 0x0022411c, op * 0x0140fc90, int 0) line 2218 
+ 9 bytes
Perl_call_sv(interpreter * 0x0022411c, sv * 0x018ffc94, long 150) line 
2139 + 15 bytes
Perl_sv_clear(interpreter * 0x0022411c, sv * 0x018c2764) line 5102 + 18 
bytes
Perl_sv_free(interpreter * 0x0022411c, sv * 0x018c2764) line 5348 + 13 bytes
do_clean_objs(interpreter * 0x0022411c, sv * 0x018c2770) line 385 + 13 bytes
S_visit(interpreter * 0x0022411c, void (interpreter *, sv *)* 0x280f78f7 
do_clean_objs(interpreter *, sv *)) line 331 + 11 bytes
Perl_sv_clean_objs(interpreter * 0x0022411c) line 424 + 14 bytes
perl_destruct(interpreter * 0x0022411c) line 496 + 9 bytes
RunPerl(int 2, char * * 0x002224b8, char * * 0x00222b48) line 206 + 12 bytes
main(int 2, char * * 0x002224b8, char * * 0x00222b48) line 18 + 18 bytes
PERL! mainCRTStartup + 227 bytes
KERNEL32! 77e814c7()

>
>-2-
>   # Perl dies without "free to wrong pool" (but with an
>   # exception dialog on win32)
>   use threads;
>   use Storable qw(nfreeze);
>
>   my $t = threads->new(\&sub1);
>
>   $t->join();
>
>   sub sub1 {
>     nfreeze {};
>   }
>
VMem::Free(void * 0x019b002c) line 202 + 3 bytes
CPerlHost::Free(void * 0x019b002c) line 59 + 34 bytes
PerlMemFree(IPerlMem * 0x002224e4, void * 0x019b002c) line 302
Perl_safesysfree(void * 0x019b002c) line 140 + 26 bytes
XS_Storable__Cxt_DESTROY(interpreter * 0x0022411c, cv * 0x018ffc94) line 
5884 + 12 bytes
Perl_pp_entersub(interpreter * 0x0022411c) line 2840 + 16 bytes
S_call_body(interpreter * 0x0022411c, op * 0x0140fc90, int 0) line 2218 
+ 9 bytes
Perl_call_sv(interpreter * 0x0022411c, sv * 0x018ffc94, long 150) line 
2139 + 15 bytes
Perl_sv_clear(interpreter * 0x0022411c, sv * 0x018c2764) line 5102 + 18 
bytes
Perl_sv_free(interpreter * 0x0022411c, sv * 0x018c2764) line 5348 + 13 bytes
do_clean_objs(interpreter * 0x0022411c, sv * 0x018c2770) line 385 + 13 bytes
S_visit(interpreter * 0x0022411c, void (interpreter *, sv *)* 0x280f78f7 
do_clean_objs(interpreter *, sv *)) line 331 + 11 bytes
Perl_sv_clean_objs(interpreter * 0x0022411c) line 424 + 14 bytes
perl_destruct(interpreter * 0x0022411c) line 496 + 9 bytes
RunPerl(int 2, char * * 0x002224b8, char * * 0x00222b48) line 206 + 12 bytes
main(int 2, char * * 0x002224b8, char * * 0x00222b48) line 18 + 18 bytes
PERL! mainCRTStartup + 227 bytes
KERNEL32! 77e814c7()




------------------------------------------------
Radan Computational Ltd.

The information contained in this message and any files transmitted with it are 
confidential and intended for the addressee(s) only.  If you have received this 
message in error or there are any problems, please notify the sender immediately.  The 
unauthorized use, disclosure, copying or alteration of this message is strictly 
forbidden.  Note that any views or opinions presented in this email are solely those 
of the author and do not necessarily represent those of Radan Computational Ltd.  The 
recipient(s) of this message should check it and any attached files for viruses: Radan 
Computational will accept no liability for any damage caused by any virus transmitted 
by this email.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to