summaryrefslogtreecommitdiff
path: root/src/os/windows/crashlog_win.cpp
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2011-02-25 22:04:38 +0000
committeralberth <alberth@openttd.org>2011-02-25 22:04:38 +0000
commit31386c42a7aa51b5b6a7abfc728b9ed4e34df0ea (patch)
tree793449a253b91916b65c373f54b4544a8c6c86b8 /src/os/windows/crashlog_win.cpp
parent1dbc0a20bed5cd85035b4f84a649c4f7386b07ab (diff)
downloadopenttd-31386c42a7aa51b5b6a7abfc728b9ed4e34df0ea.tar.xz
(svn r22145) -Codechange: Do explicit test for non-bool values.
Diffstat (limited to 'src/os/windows/crashlog_win.cpp')
-rw-r--r--src/os/windows/crashlog_win.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/os/windows/crashlog_win.cpp b/src/os/windows/crashlog_win.cpp
index a975603dd..2fd930d19 100644
--- a/src/os/windows/crashlog_win.cpp
+++ b/src/os/windows/crashlog_win.cpp
@@ -526,7 +526,7 @@ static LONG WINAPI ExceptionHandler(EXCEPTION_POINTERS *ep)
/* Close any possible log files */
CloseConsoleLogIfActive();
- if (_safe_esp) {
+ if (_safe_esp != NULL) {
#ifdef _M_AMD64
ep->ContextRecord->Rip = (DWORD64)ShowCrashlogWindow;
ep->ContextRecord->Rsp = (DWORD64)_safe_esp;
@@ -605,7 +605,7 @@ static void SetWndSize(HWND wnd, int mode)
if (mode >= 0) {
GetWindowRect(GetDlgItem(wnd, 11), &r2);
int offs = r2.bottom - r2.top + 10;
- if (!mode) offs = -offs;
+ if (mode == 0) offs = -offs;
SetWindowPos(wnd, HWND_TOPMOST, 0, 0,
r.right - r.left, r.bottom - r.top + offs, SWP_NOMOVE | SWP_NOZORDER);
} else {