Alexandre Julliard : gdi32/tests: Fix the GetObject last error check for most Windows versions.

Alexandre Julliard julliard at winehq.org
Mon Aug 23 10:50:13 CDT 2010


Module: wine
Branch: master
Commit: abafd9f1c73d11eadd249e1eddff0c2328ea97d5
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=abafd9f1c73d11eadd249e1eddff0c2328ea97d5

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Mon Aug 23 11:11:16 2010 +0200

gdi32/tests: Fix the GetObject last error check for most Windows versions.

---

 dlls/gdi32/tests/gdiobj.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/gdi32/tests/gdiobj.c b/dlls/gdi32/tests/gdiobj.c
index 7302134..6367071 100644
--- a/dlls/gdi32/tests/gdiobj.c
+++ b/dlls/gdi32/tests/gdiobj.c
@@ -85,7 +85,7 @@ static void test_gdi_objects(void)
     hp = SelectObject(hdc, GetStockObject(BLACK_PEN));
     SetLastError(0);
     i = GetObjectA(hp, (INT_PTR)buff, (LPVOID)sizeof(buff));
-    ok (!i && GetLastError() == ERROR_NOACCESS,
+    ok (!i && (GetLastError() == 0 || GetLastError() == ERROR_NOACCESS),
         "GetObject(invalid buff), expected 0, ERROR_NOACCESS, got %d, %u\n",
     i, GetLastError());
 




More information about the wine-cvs mailing list