James Hawkins : gdi32: Remove a dependence on the amount of available memory.

Alexandre Julliard julliard at winehq.org
Fri Apr 25 08:10:56 CDT 2008


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

Author: James Hawkins <jhawkins at codeweavers.com>
Date:   Thu Apr 24 20:47:44 2008 -0500

gdi32: Remove a dependence on the amount of available memory.

---

 dlls/gdi32/tests/bitmap.c |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/dlls/gdi32/tests/bitmap.c b/dlls/gdi32/tests/bitmap.c
index f7bfdfd..00441c0 100644
--- a/dlls/gdi32/tests/bitmap.c
+++ b/dlls/gdi32/tests/bitmap.c
@@ -974,9 +974,13 @@ static void test_bitmap(void)
 
     SetLastError(0xdeadbeef);
     hbmp = CreateBitmap(0x7ffffff, 9, 1, 1, NULL);
-    ok(!hbmp, "CreateBitmap should fail\n");
-    ok(GetLastError() == ERROR_NOT_ENOUGH_MEMORY,
-       "expected ERROR_NOT_ENOUGH_MEMORY, got %u\n", GetLastError());
+    if (!hbmp)
+    {
+        ok(GetLastError() == ERROR_NOT_ENOUGH_MEMORY,
+           "expected ERROR_NOT_ENOUGH_MEMORY, got %u\n", GetLastError());
+    }
+    else
+        DeleteObject(hbmp);
 
     SetLastError(0xdeadbeef);
     hbmp = CreateBitmap(0x7ffffff + 1, 1, 1, 1, NULL);




More information about the wine-cvs mailing list