From 1899dff4b7dacb47136c3d91f274d8300dc16310 Mon Sep 17 00:00:00 2001 From: Buginator Date: Sat, 10 Oct 2009 00:42:42 +0000 Subject: [PATCH] Add a ASSERT() to the --crash test (only on DEBUG builds) since some people are accidentally releasing debug builds instead of release builds and this will be a quick way to check. Read http://developer.wz2100.net/wiki/ReleaseChecklist git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@8245 4a71c877-e1ca-e34f-864e-861f7616d084 --- src/display3d.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/display3d.c b/src/display3d.c index 57d3a40ab..6893fc2e5 100644 --- a/src/display3d.c +++ b/src/display3d.c @@ -594,6 +594,10 @@ void draw3DScene( void ) if (CauseCrash) { char *crash = 0; +#ifdef DEBUG + ASSERT(false, "Yes, this is a assert. This should not happen on release builds! Use --noassert to bypass in debug builds."); + debug(LOG_WARNING, " *** Warning! You have compiled in debug mode! ***"); +#endif debug(LOG_ERROR, "Forcing a segfault! (crash handler test)"); // and here comes the crash *crash = 0x3;