Michael Stefaniuc : fusion/tests: Simplify the check for an empty string ( PVS-Studio).

Alexandre Julliard julliard at wine.codeweavers.com
Fri Nov 14 07:30:17 CST 2014


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

Author: Michael Stefaniuc <mstefani at redhat.de>
Date:   Fri Nov 14 11:05:00 2014 +0100

fusion/tests: Simplify the check for an empty string (PVS-Studio).

---

 dlls/fusion/tests/asmname.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/fusion/tests/asmname.c b/dlls/fusion/tests/asmname.c
index ac5b27b..a075288 100644
--- a/dlls/fusion/tests/asmname.c
+++ b/dlls/fusion/tests/asmname.c
@@ -425,7 +425,7 @@ static void test_CreateAssemblyNameObject(void)
     str[0] = '\0';
     hr = IAssemblyName_GetName(name, &size, str);
     ok(hr == S_OK, "Expected S_OK, got %08x\n", hr);
-    ok(lstrlenW(str) == 0, "Expected empty name\n");
+    ok(!str[0], "Expected empty name\n");
     ok(size == 0, "Expected 0, got %d\n", size);
 
     hi = 0xbeefcace;
@@ -461,7 +461,7 @@ static void test_CreateAssemblyNameObject(void)
     str[0] = '\0';
     hr = IAssemblyName_GetName(name, &size, str);
     ok(hr == S_OK, "Expected S_OK, got %08x\n", hr);
-    ok(lstrlenW(str) == 0, "Expected empty name\n");
+    ok(!str[0], "Expected empty name\n");
     ok(size == 1, "Expected 1, got %d\n", size);
 
     hi = 0xbeefcace;




More information about the wine-cvs mailing list