diff --git a/reactos/subsystems/win32/win32k/ntuser/window.c b/reactos/subsystems/win32/win32k/ntuser/window.c index eaa89d4b5eb..328775bee8a 100644 --- a/reactos/subsystems/win32/win32k/ntuser/window.c +++ b/reactos/subsystems/win32/win32k/ntuser/window.c @@ -4562,7 +4562,7 @@ NtUserDefSetText(HWND hWnd, PUNICODE_STRING WindowText) UserEnterExclusive(); - if(!(Window = UserGetWindowObject(hWnd))) + if(!(Window = UserGetWindowObject(hWnd)) || !Window->Wnd) { UserLeave(); return FALSE;