| |||
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] |
Hi,
I'm trying to catch an exception using a set_terminate handler, which
re-throws the exception and tries to catch it using a number of
templates, including "...". On Linux, this works fine; on OS X, the
handler gets stuck in an endless recursion, re-throwing the exception
and being called over and over again.
I've attached the problematic isolated code; the output is as follows:
On OSX 10.2.6, gcc 3.1 20020420 (prerelease):
$ gcc -o testprogram Main.cc -lstdc++
$ ./testprogram
Re-throwing.
Re-throwing.
Re-throwing.
[... etc until the stack overflows]
On Linux 2.4.19, gcc 3.2:
$ gcc -o testprogram Main.cc -lstdc++
$ ./testprogram
Re-throwing.
MyException
Aborted
| References: | |
| >Trouble with C++ exceptions (From: Björn Giesler <email@hidden>) |
| Home | Archives | FAQ | Terms/Conditions | Contact | RSS | Lists | About |
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2007 Apple Inc. All rights reserved.