On fredag, feb 7, 2003, at 01:13 Europe/Stockholm, A. Bergman wrote:
Getting some weird coredumps, recompile with debugging, and breakpoint on Perl_croak gave me this.That stack trace is bogus, current theory is that when perl loads a xs module there is stack corruption, the backtrace from GDB is wildly incorrect!
#0 Perl_croak (pat=0xae7ca0 "Assertion ((sv)->sv_flags & (0x00002000|0x00004000|0x00008000)) failed: file \"%s\", line %d") at util.c:1349
#1 0x00a0176c in S_save_magic (mgs_ix=20, sv=0x50d7dc) at mg.c:59
#2 0x00a01b24 in Perl_mg_set (sv=0x50d7dc) at mg.c:170
#3 0x0098c934 in S_init_postdump_symbols (argc=1, argv=0x50a6a4, env=0x50e5f8) at perl.c:3630
#4 0x00986138 in S_parse_body (env=0x0, xsinit=0x60f6a4 <modperl_xs_init>) at perl.c:1480
#5 0x00984d54 in perl_parse (my_perl=0x3f59f0, xsinit=0x60f6a4 <modperl_xs_init>, argc=2, argv=0x40a248, env=0x0) at perl.c:1041
#6 0x0060f800 in modperl_startup (s=0x4062d8, p=0x3bd548) at mod_perl.c:140
#7 0x0060fb78 in modperl_init (base_server=0x4062d8, p=0x3bd548) at mod_perl.c:317
#8 0x0060fd6c in modperl_hook_init (pconf=0x3bd548, plog=0x401078, ptemp=0x4070a8, s=0x4062d8) at mod_perl.c:448
#9 0x00055b9c in ap_run_open_logs (pconf=0x3bd548, plog=0x401078, ptemp=0x4070a8, s=0x4062d8) at config.c:188
#10 0x00045458 in main (argc=2, argv=0xbffffbb0) at main.c:634
#11 0x0000276c in _start (argc=2, argv=0xbffffbb0, envp=0xbffffbbc) at /SourceCache/Csu/Csu-45/crt.c:267
#12 0x000025ec in start ()
The abused code in perl.c seems to do
sv = newSVpv(s+1, 0);
(void)hv_store(hv, *env, s - *env, sv, 0);
if (env != environ)
mg_set(sv);
}
Now sv can hardly be magical there so the line seems bogus, or maybe it should get some magic by PERL_MAGIC_env.
Will continue debugging tomorrow.
Arthur
Arthur
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
