Michael Stefaniuc : shell32/tests: Actually test some return values ( PVS-Studio).

Alexandre Julliard julliard at wine.codeweavers.com
Wed Mar 4 09:22:17 CST 2015


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

Author: Michael Stefaniuc <mstefani at redhat.de>
Date:   Wed Mar  4 09:50:59 2015 +0100

shell32/tests: Actually test some return values (PVS-Studio).

---

 dlls/shell32/tests/shellpath.c | 1 +
 dlls/shell32/tests/systray.c   | 1 +
 2 files changed, 2 insertions(+)

diff --git a/dlls/shell32/tests/shellpath.c b/dlls/shell32/tests/shellpath.c
index e2277ec..af88c6b 100644
--- a/dlls/shell32/tests/shellpath.c
+++ b/dlls/shell32/tests/shellpath.c
@@ -2107,6 +2107,7 @@ static void test_knownFolders(void)
             ok(IsEqualGUID(&folderId, &FOLDERID_Windows)==TRUE, "invalid KNOWNFOLDERID returned\n");
 
             hr = IKnownFolder_GetPath(folder, 0, &folderPath);
+            ok(hr == S_OK, "failed to get path from known folder: 0x%08x\n", hr);
             ok(lstrcmpiW(sWinDir, folderPath)==0, "invalid path returned: \"%s\", expected: \"%s\"\n", wine_dbgstr_w(folderPath), wine_dbgstr_w(sWinDir));
             CoTaskMemFree(folderPath);
 
diff --git a/dlls/shell32/tests/systray.c b/dlls/shell32/tests/systray.c
index cb27866..0d815a6 100644
--- a/dlls/shell32/tests/systray.c
+++ b/dlls/shell32/tests/systray.c
@@ -45,6 +45,7 @@ static void test_cbsize(void)
         nidW.hIcon = LoadIconA(NULL, (LPSTR)IDI_APPLICATION);
         nidW.uCallbackMessage = WM_USER+17;
         ret = pShell_NotifyIconW(NIM_ADD, &nidW);
+        ok(ret, "NIM_ADD failed!\n");
         /* using an invalid cbSize does work */
         nidW.cbSize = 3;
         nidW.hWnd = hMainWnd;




More information about the wine-cvs mailing list