[wxMac only?] Exception sample not working
H
H at h.com
Tue Jan 22 13:47:29 PST 2008
In article <20080122002358.2C4F88059009 at bifrost.dotsrc.org>,
vadim at wxwidgets.org (Vadim Zeitlin) wrote:
> On Sat, 19 Jan 2008 08:26:25 +0100 H <H at h.com> wrote:
>
> H> Currently I have tested 2.8 branch latest version but I also tested it
> H> sporadically since 2.7:
> H>
> H> Compiling wx with the configuration
> H>
> H> ./configure --with-mac --enable-debug --enable-unicode
> H> --disable-universal --disable-monolithic --enable-gui --disable-shared
> H> --enable-exceptions --without-odbc --with-opengl
> H>
> H> entering make and going to the sample folder except and also entering
> H> make results in a sample that:
> H>
> H> - catches thrown strings -> OK
> H> - crashes badly when ints and objects are thrown.
>
> I don't know about Mac and can't test the code there right now but with
> wxGTK except sample has the same behaviour so maybe wxMac has the same
> problem, although I can't explain why would it happen there. As for wxGTK,
> in 2.8 the code relies on undefined behaviour as it lets C++ exceptions
> propagate through C code. This works just fine under Windows but doesn't
> work under Linux at all (except for strings apparently but, again, I really
> can't explain this). We fixed it in the trunk where the exceptions are
> caught before the control returns to GTK+ code and the except sample works
> fine there. Have you tried the trunk version under Mac?
>
> Regards,
> VZ
Just downloaded trunk revision 51338 and recompiled: still crashes
badly! It seems to be that the exception is not caught at all and just
terminate() is called.
See dump:
Thread 0 Crashed:
0 libSystem.B.dylib 0x93a25ca8 __kill + 12
1 libSystem.B.dylib 0x93aca7b4 abort + 84
2 libstdc++.6.dylib 0x947dee24
__gnu_cxx::__verbose_terminate_handler() + 400
3 libstdc++.6.dylib 0x947dc940 __gxx_personality_v0 +
1240
4 libstdc++.6.dylib 0x947dc9a4 std::terminate() + 68
5 libstdc++.6.dylib 0x947dcbe4 __cxa_throw + 124
6 org.wxwindows.samples.except 0x00004540
MyFrame::OnThrowInt(wxCommandEvent&) + 80 (except.cpp:408)
Hartwig
More information about the wx-users
mailing list