From 5f449727e11922965790d1c9e16dece20f6aa7e4 Mon Sep 17 00:00:00 2001 From: David Rose Date: Mon, 21 Jul 2003 15:01:49 +0000 Subject: [PATCH] DebugBreak() still not quite right --- dtool/src/dconfig/notify.cxx | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/dtool/src/dconfig/notify.cxx b/dtool/src/dconfig/notify.cxx index ce40c7eab4..cda51ddc0a 100644 --- a/dtool/src/dconfig/notify.cxx +++ b/dtool/src/dconfig/notify.cxx @@ -434,11 +434,15 @@ assert_failure(const char *expression, int line, // the debugger? abort() doesn't do it. We used to be able to // assert(false), but in VC++ 7 that just throws an exception, and // an uncaught exception just exits, without offering to open the - // debugger. Guess we'll have to force a segfault. + // debugger. -// int *ptr = (int *)NULL; -// *ptr = 1; - DebugBreak(); + // DebugBreak() seems to be provided for this purpose, but it + // doesn't seem to work properly either, since we don't seem to + // get a reliable stack trace. + + // Guess we'll still have to force a segfault. + int *ptr = (int *)NULL; + *ptr = 1; #else abort(); #endif