Author: pschweitzer
Date: Sun Apr 6 13:38:06 2014
New Revision: 62654
URL:
http://svn.reactos.org/svn/reactos?rev=62654&view=rev
Log:
[DESK]
Fix leaks
CID #716336
CID #716337
Modified:
trunk/reactos/dll/cpl/desk/background.c
trunk/reactos/dll/cpl/desk/screensaver.c
Modified: trunk/reactos/dll/cpl/desk/background.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/background.c?…
==============================================================================
--- trunk/reactos/dll/cpl/desk/background.c [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/desk/background.c [iso-8859-1] Sun Apr 6 13:38:06 2014
@@ -288,7 +288,7 @@
}
if(!FindNextFile(hFind, &fd))
- hFind = INVALID_HANDLE_VALUE;
+ break;
}
token = _tcstok(NULL, separators);
Modified: trunk/reactos/dll/cpl/desk/screensaver.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/desk/screensaver.c…
==============================================================================
--- trunk/reactos/dll/cpl/desk/screensaver.c [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/desk/screensaver.c [iso-8859-1] Sun Apr 6 13:38:06 2014
@@ -65,7 +65,10 @@
(LPBYTE)lpBuf,
&BufSize);
if (Ret != ERROR_SUCCESS)
+ {
+ HeapFree(GetProcessHeap(), 0, lpBuf);
lpBuf = NULL;
+ }
}
}