Author: pschweitzer
Date: Sun Oct 2 12:22:39 2011
New Revision: 53923
URL:
http://svn.reactos.org/svn/reactos?rev=53923&view=rev
Log:
[APPWIZ]
Fix memory leaks
Modified:
trunk/reactos/dll/cpl/appwiz/createlink.c
Modified: trunk/reactos/dll/cpl/appwiz/createlink.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/cpl/appwiz/createlink.…
==============================================================================
--- trunk/reactos/dll/cpl/appwiz/createlink.c [iso-8859-1] (original)
+++ trunk/reactos/dll/cpl/appwiz/createlink.c [iso-8859-1] Sun Oct 2 12:22:39 2011
@@ -335,6 +335,8 @@
nLength = wcslen(szPath);
if (!nLength)
{
+ HeapFree(GetProcessHeap(), 0, pContext);
+
/* no directory given */
return FALSE;
}
@@ -342,6 +344,8 @@
attrs = GetFileAttributesW(szPath);
if (attrs == INVALID_FILE_ATTRIBUTES)
{
+ HeapFree(GetProcessHeap(), 0, pContext);
+
/* invalid path */
return FALSE;
}