[PATCH] shell32: Properly handle SHGetPathFromIDListW failure (PVS-Studio)
Nikolay Sivov
nsivov at codeweavers.com
Tue Oct 20 08:44:49 CDT 2015
Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
---
dlls/shell32/brsfolder.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/shell32/brsfolder.c b/dlls/shell32/brsfolder.c
index 1a2716e..4040407 100644
--- a/dlls/shell32/brsfolder.c
+++ b/dlls/shell32/brsfolder.c
@@ -757,9 +757,10 @@ static HRESULT BrsFolder_NewFolder(browse_info *info)
if(FAILED(hr))
return hr;
- hr = SHGetPathFromIDListW(info->pidlRet, name);
- if(FAILED(hr))
+ if(!SHGetPathFromIDListW(info->pidlRet, name)) {
+ hr = E_FAIL;
goto cleanup;
+ }
len = strlenW(name);
if(len<MAX_PATH)
--
2.6.1
More information about the wine-patches
mailing list