Nikolay Sivov : shell32: Fix a cloned pidl leak (Coverity).

Alexandre Julliard julliard at winehq.org
Thu Apr 10 12:21:28 CDT 2014


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

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Thu Apr 10 09:22:44 2014 +0400

shell32: Fix a cloned pidl leak (Coverity).

---

 dlls/shell32/shlfolder.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/dlls/shell32/shlfolder.c b/dlls/shell32/shlfolder.c
index 1b53edf..0fb8df9 100644
--- a/dlls/shell32/shlfolder.c
+++ b/dlls/shell32/shlfolder.c
@@ -531,11 +531,11 @@ HRESULT SHELL32_CompareIDs(IShellFolder2 *sf, LPARAM lParam, LPCITEMIDLIST pidl1
     isEmpty2 = _ILIsDesktop (nextpidl2);
 
     if (isEmpty1 && isEmpty2) {
-        return MAKE_HRESULT( SEVERITY_SUCCESS, 0, 0 );
+        nReturn = MAKE_HRESULT( SEVERITY_SUCCESS, 0, 0 );
     } else if (isEmpty1) {
-        return MAKE_HRESULT( SEVERITY_SUCCESS, 0, (WORD)-1 );
+        nReturn = MAKE_HRESULT( SEVERITY_SUCCESS, 0, (WORD)-1 );
     } else if (isEmpty2) {
-        return MAKE_HRESULT( SEVERITY_SUCCESS, 0, 1 );
+        nReturn = MAKE_HRESULT( SEVERITY_SUCCESS, 0, 1 );
     /* optimizing end */
     } else if (SUCCEEDED(IShellFolder2_BindToObject(sf, firstpidl, NULL, &IID_IShellFolder, (void **)&psf))) {
 	nReturn = IShellFolder_CompareIDs (psf, lParam, nextpidl1, nextpidl2);




More information about the wine-cvs mailing list