Cezary Morga wrote:
Hi,
Thanks for your response. Last week I've came upon this thread
http://www.nabble.com/free-from-wrong-pool-during-global-destruction-td23059712.html
which made me try PL_use_safe_putenv=1 (patch below) and it seems it did
the trick. The 'assertion failed' messages comes from malloc() with
debugging on (8-CURRENT is a development branch after all), so I'd guess
it's more of a Perl working around putenv() issue than Wx itself. What
do you think?
I agree the issue is in Perl and not in Wx. However I do not think
it is safe to apply the patch below. IMHO the fact that loading Wx
globally changes the value of use_safe_putenv is bad, and I only did it
when DEBUGGING is set because it is the only case where I know it's
absolutely necessary. I'd rather not do it unconditionally for all perl
builds.
Regards,
Mattia
--- Wx.xs.orig 2009-04-20 22:17:27.000000000 +0200
+++ Wx.xs 2009-06-26 09:20:07.000000000 +0200
@@ -278,10 +278,7 @@ Load()
if( wxPerlAppCreated || wxTopLevelWindows.GetCount() > 0 )
return;
-#if defined(DEBUGGING) && !defined(PERL_USE_SAFE_PUTENV)
- // avoid crash on exit in Fedora (and other DEBUGGING Perls)
PL_use_safe_putenv = 1;
-#endif
int argc = 0;
#if wxUSE_UNICODE && WXPERL_W_VERSION_GE( 2, 5, 3 )