mirror of
https://github.com/reactos/reactos.git
synced 2024-11-19 05:22:59 +00:00
Correct error returns for GetObject and GetObjectType based on Wine tests.
svn path=/trunk/; revision=21007
This commit is contained in:
parent
f125cf5904
commit
78a1fa7053
1 changed files with 5 additions and 1 deletions
|
@ -249,6 +249,8 @@ GetObjectA(HGDIOBJ Handle, int Size, LPVOID Buffer)
|
|||
Type = NtGdiGetObjectType(Handle);
|
||||
if (0 == Type)
|
||||
{
|
||||
/* From Wine: GetObject does not SetLastError() on a null object */
|
||||
SetLastError(0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -448,6 +450,8 @@ GetObjectType(
|
|||
break;
|
||||
}
|
||||
}
|
||||
|
||||
else
|
||||
/* From Wine: GetObjectType does SetLastError() on a null object */
|
||||
SetLastError(ERROR_INVALID_HANDLE);
|
||||
return Ret;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue