mirror of
https://github.com/reactos/reactos.git
synced 2025-02-25 09:50:02 +00:00
patch from w3seek : Another fix for NtUserFindWindowEx
svn path=/trunk/; revision=21957
This commit is contained in:
parent
3e649bb0dc
commit
7ece217a3e
1 changed files with 12 additions and 8 deletions
|
@ -2444,13 +2444,16 @@ NtUserFindWindowEx(HWND hwndParent,
|
|||
ClassName.Length,
|
||||
sizeof(WCHAR));
|
||||
}
|
||||
else if (IS_ATOM(ClassName.Buffer))
|
||||
else if (ClassName.Buffer != NULL && !IS_ATOM(ClassName.Buffer))
|
||||
{
|
||||
if (!IntGetAtomFromStringOrAtom(&ClassName,
|
||||
&ClassAtom))
|
||||
{
|
||||
_SEH_LEAVE;
|
||||
}
|
||||
SetLastWin32Error(ERROR_INVALID_PARAMETER);
|
||||
_SEH_LEAVE;
|
||||
}
|
||||
|
||||
if (!IntGetAtomFromStringOrAtom(&ClassName,
|
||||
&ClassAtom))
|
||||
{
|
||||
_SEH_LEAVE;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2472,9 +2475,10 @@ NtUserFindWindowEx(HWND hwndParent,
|
|||
}
|
||||
_SEH_END;
|
||||
|
||||
if (ucClassName != NULL && ClassName.Length == 0)
|
||||
if (ucClassName != NULL)
|
||||
{
|
||||
if (!IS_ATOM(ClassName.Buffer))
|
||||
if (ClassName.Length == 0 && ClassName.Buffer != NULL &&
|
||||
!IS_ATOM(ClassName.Buffer))
|
||||
{
|
||||
SetLastWin32Error(ERROR_INVALID_PARAMETER);
|
||||
RETURN(NULL);
|
||||
|
|
Loading…
Reference in a new issue