PRB: Longjmp Inside a _try Block Fails on PowerPC (153005)
The information in this article applies to:
- Microsoft Visual C++, 32-bit Professional Edition 4.1
This article was previously published under Q153005 SYMPTOMS
A program that contains a longjmp called inside a _try block may not call a
_finally block. The sample code below is verified to work consistently on
Alpha, MIPS and Intel platforms. It fails only on Power PC.
WORKAROUND
The solution is to include the setjmpex.h file instead of setjmp.h. The
latter provides consistent behavior on all platforms, but may cause a
performance degradation. Note: either setjmp.h or setjmpex.h may be
included, but not both, because each defines the setjmp macro in a
different way.
STATUS
This behavior is by design.
Modification Type: | Minor | Last Reviewed: | 7/5/2005 |
---|
Keywords: | kbprb KB153005 |
---|
|