From 1ce0c09e21908c25d0670d5cae2bc4fc0acaa991 Mon Sep 17 00:00:00 2001 From: rfm Date: Tue, 23 May 2006 13:57:38 +0000 Subject: [PATCH] Tweak to dusable stacktrace when built without debug information. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@22974 72102866-910b-0410-8b05-ffd578937521 --- ChangeLog | 2 ++ Source/NSException.m | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/ChangeLog b/ChangeLog index 0953bd630..169ce133a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,8 @@ * Source/Additions/GSMime.m: Fix some cases where parse was saying it needed more data even though it had actually completed. + * Source/NSException.m: Don't add stacktrace information if we are + not building with debug on. 2006-05-22 Richard Frith-Macdonald diff --git a/Source/NSException.m b/Source/NSException.m index d5510c2fc..938c8ad99 100644 --- a/Source/NSException.m +++ b/Source/NSException.m @@ -46,6 +46,16 @@ #endif #endif +/* + * Turn off STACKTRACE if we don't have DEBUG defined ... if we are not built + * with DEBUG then we are probably missing stackframe information etc. + */ +#if !(defined(DEBUG)) +#if defined(STACKTRACE) +#undef STACKTRACE +#endif +#endif + #if defined(STACKTRACE) // GSStackTrace inspired by FYStackTrace.m