From 15085aa7f47c06cb794a62a85240fdf12ca06bbc Mon Sep 17 00:00:00 2001 From: glx Date: Sun, 9 Dec 2007 21:20:21 +0000 Subject: (svn r11611) -Codechange: it is now possible to use a define to enable asserts and show them in crash.log for MSVC release builds --- src/win32.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/win32.cpp') diff --git a/src/win32.cpp b/src/win32.cpp index 0e3d4f4ef..b1e143d4f 100644 --- a/src/win32.cpp +++ b/src/win32.cpp @@ -81,6 +81,17 @@ bool LoadLibraryList(Function proc[], const char *dll) #ifdef _MSC_VER static const char *_exception_string = NULL; +void SetExceptionString(const char *s, ...) +{ + va_list va; + char buf[512]; + + va_start(va, s); + vsnprintf(buf, lengthof(buf), s, va); + va_end(va); + + _exception_string = strdup(buf); +} #endif void ShowOSErrorBox(const char *buf) -- cgit v1.2.3-70-g09d2