From 0ba2b569e205c797b297e8a3388d97e277d42bb3 Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Sun, 12 Nov 2000 03:43:42 +0000 Subject: [PATCH] The debugger "Auto" registry value should be a string. --- win32/except.c | 10 ++++++++-- winedefault.reg | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/win32/except.c b/win32/except.c index 4ed10333e61..0acd1c0138a 100644 --- a/win32/except.c +++ b/win32/except.c @@ -192,7 +192,7 @@ DWORD WINAPI UnhandledExceptionFilter(PEXCEPTION_POINTERS epointers) &hDbgConf)) { DWORD type; DWORD count; - + count = sizeof(format); if (RegQueryValueExA(hDbgConf, "Debugger", 0, &type, format, &count)) format[0] = 0; @@ -200,7 +200,13 @@ DWORD WINAPI UnhandledExceptionFilter(PEXCEPTION_POINTERS epointers) count = sizeof(bAuto); if (RegQueryValueExA(hDbgConf, "Auto", 0, &type, (char*)&bAuto, &count)) bAuto = TRUE; - + else if (type == REG_SZ) + { + char autostr[10]; + count = sizeof(autostr); + if (!RegQueryValueExA(hDbgConf, "Auto", 0, &type, autostr, &count)) + bAuto = atoi(autostr); + } RegCloseKey(hDbgConf); } else { /* format[0] = 0; */ diff --git a/winedefault.reg b/winedefault.reg index 672b5f9b3af..7b455a0d57e 100644 --- a/winedefault.reg +++ b/winedefault.reg @@ -87,7 +87,7 @@ # command line to start a debugger when an exception occurs "Debugger"="debugger/winedbg %ld %ld" # to 0 if a message box has to be presented before running the debugger -"Auto"=dword:00000001 +"Auto"="1" # # This identifies the files for available code pages