Nikolay Sivov : shlwapi: Fix SHPropertyBag_ReadLONG prototype (PVS-Studio) .
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Oct 15 10:27:59 CDT 2015
Module: wine
Branch: master
Commit: f51e7900eb5714edfff2b9b411b10e7d4999bf34
URL: http://source.winehq.org/git/wine.git/?a=commit;h=f51e7900eb5714edfff2b9b411b10e7d4999bf34
Author: Nikolay Sivov <nsivov at codeweavers.com>
Date: Thu Oct 15 12:44:20 2015 +0300
shlwapi: Fix SHPropertyBag_ReadLONG prototype (PVS-Studio).
Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/shlwapi/ordinal.c | 4 ++--
dlls/shlwapi/tests/ordinal.c | 10 ++++------
2 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/dlls/shlwapi/ordinal.c b/dlls/shlwapi/ordinal.c
index df15c40..3c8af5c 100644
--- a/dlls/shlwapi/ordinal.c
+++ b/dlls/shlwapi/ordinal.c
@@ -5187,9 +5187,9 @@ HRESULT WINAPI IUnknown_QueryServiceForWebBrowserApp(IUnknown* lpUnknown,
* pValue: address to receive the property value as a 32-bit signed integer
*
* RETURNS
- * 0 for Success
+ * HRESULT codes
*/
-BOOL WINAPI SHPropertyBag_ReadLONG(IPropertyBag *ppb, LPCWSTR pszPropName, LPLONG pValue)
+HRESULT WINAPI SHPropertyBag_ReadLONG(IPropertyBag *ppb, LPCWSTR pszPropName, LPLONG pValue)
{
VARIANT var;
HRESULT hr;
diff --git a/dlls/shlwapi/tests/ordinal.c b/dlls/shlwapi/tests/ordinal.c
index 17edf65..68526cd 100644
--- a/dlls/shlwapi/tests/ordinal.c
+++ b/dlls/shlwapi/tests/ordinal.c
@@ -1633,21 +1633,19 @@ static void test_SHPropertyBag_ReadLONG(void)
out = 0xfeedface;
rc = pSHPropertyBag_ReadLONG(NULL, szName1, &out);
- ok(rc == E_INVALIDARG || broken(rc == 0), "incorrect return %x\n",rc);
+ ok(rc == E_INVALIDARG || broken(rc == S_OK), "incorrect return %x\n",rc);
ok(out == 0xfeedface, "value should not have changed\n");
rc = pSHPropertyBag_ReadLONG(&pb->IPropertyBag_iface, NULL, &out);
- ok(rc == E_INVALIDARG || broken(rc == 0) || broken(rc == 1), "incorrect return %x\n",rc);
+ ok(rc == E_INVALIDARG || broken(rc == S_OK) || broken(rc == S_FALSE), "incorrect return %x\n",rc);
ok(out == 0xfeedface, "value should not have changed\n");
rc = pSHPropertyBag_ReadLONG(&pb->IPropertyBag_iface, szName1, NULL);
- ok(rc == E_INVALIDARG || broken(rc == 0) || broken(rc == 1), "incorrect return %x\n",rc);
+ ok(rc == E_INVALIDARG || broken(rc == S_OK) || broken(rc == S_FALSE), "incorrect return %x\n",rc);
rc = pSHPropertyBag_ReadLONG(&pb->IPropertyBag_iface, szName1, &out);
- ok(rc == DISP_E_BADVARTYPE || broken(rc == 0) || broken(rc == 1), "incorrect return %x\n",rc);
+ ok(rc == DISP_E_BADVARTYPE || broken(rc == S_OK) || broken(rc == S_FALSE), "incorrect return %x\n",rc);
ok(out == 0xfeedface || broken(out == 0xfeedfa00), "value should not have changed %x\n",out);
IUnknown_Release((IUnknown*)pb);
}
-
-
static void test_SHSetWindowBits(void)
{
HWND hwnd;
More information about the wine-cvs
mailing list