Author: pschweitzer
Date: Sat Apr 5 22:31:19 2014
New Revision: 62638
URL:
http://svn.reactos.org/svn/reactos?rev=62638&view=rev
Log:
[SERVMAN]
- Call LocalFree() to free memory allocated with LocalAlloc()
- Fix leak
CID #716291
CID #1101891
CID #1101892
CID #1101893
CID #1101894
CID #1101895
CID #1101896
Modified:
trunk/reactos/base/applications/mscutils/servman/create.c
trunk/reactos/base/applications/mscutils/servman/delete.c
trunk/reactos/base/applications/mscutils/servman/dependencies_tv1.c
trunk/reactos/base/applications/mscutils/servman/dependencies_tv2.c
trunk/reactos/base/applications/mscutils/servman/listview.c
trunk/reactos/base/applications/mscutils/servman/stop_dependencies.c
Modified: trunk/reactos/base/applications/mscutils/servman/create.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
==============================================================================
--- trunk/reactos/base/applications/mscutils/servman/create.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/mscutils/servman/create.c [iso-8859-1] Sat Apr 5
22:31:19 2014
@@ -65,9 +65,7 @@
{
DisplayString(lpSuccess);
- HeapFree(ProcessHeap,
- 0,
- lpSuccess);
+ LocalFree(lpSuccess);
}
CloseServiceHandle(hSc);
Modified: trunk/reactos/base/applications/mscutils/servman/delete.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
==============================================================================
--- trunk/reactos/base/applications/mscutils/servman/delete.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/mscutils/servman/delete.c [iso-8859-1] Sat Apr 5
22:31:19 2014
@@ -38,9 +38,7 @@
{
DisplayString(lpSuccess);
- HeapFree(ProcessHeap,
- 0,
- lpSuccess);
+ LocalFree(lpSuccess);
}
bRet = TRUE;
Modified: trunk/reactos/base/applications/mscutils/servman/dependencies_tv1.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
==============================================================================
--- trunk/reactos/base/applications/mscutils/servman/dependencies_tv1.c [iso-8859-1]
(original)
+++ trunk/reactos/base/applications/mscutils/servman/dependencies_tv1.c [iso-8859-1] Sat
Apr 5 22:31:19 2014
@@ -163,9 +163,7 @@
0,
FALSE);
- HeapFree(ProcessHeap,
- 0,
- lpNoDepends);
+ LocalFree(lpNoDepends);
/* Disable the window */
EnableWindow(pDlgInfo->hDependsTreeView1, FALSE);
Modified: trunk/reactos/base/applications/mscutils/servman/dependencies_tv2.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
==============================================================================
--- trunk/reactos/base/applications/mscutils/servman/dependencies_tv2.c [iso-8859-1]
(original)
+++ trunk/reactos/base/applications/mscutils/servman/dependencies_tv2.c [iso-8859-1] Sat
Apr 5 22:31:19 2014
@@ -41,6 +41,8 @@
bRet = TRUE;
}
}
+
+ CloseServiceHandle(hService);
}
CloseServiceHandle(hSCManager);
@@ -163,9 +165,7 @@
0,
FALSE);
- HeapFree(ProcessHeap,
- 0,
- lpNoDepends);
+ LocalFree(lpNoDepends);
/* Disable the window */
EnableWindow(pDlgInfo->hDependsTreeView2, FALSE);
Modified: trunk/reactos/base/applications/mscutils/servman/listview.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
==============================================================================
--- trunk/reactos/base/applications/mscutils/servman/listview.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/mscutils/servman/listview.c [iso-8859-1] Sat Apr 5
22:31:19 2014
@@ -192,9 +192,7 @@
lvItem.iItem,
(LPARAM)&lvItem);
- HeapFree(ProcessHeap,
- 0,
- lpStartup);
+ LocalFree(lpStartup);
HeapFree(ProcessHeap,
0,
lpServiceConfig);
Modified: trunk/reactos/base/applications/mscutils/servman/stop_dependencies.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/mscutils…
==============================================================================
--- trunk/reactos/base/applications/mscutils/servman/stop_dependencies.c [iso-8859-1]
(original)
+++ trunk/reactos/base/applications/mscutils/servman/stop_dependencies.c [iso-8859-1] Sat
Apr 5 22:31:19 2014
@@ -238,9 +238,7 @@
bRet = TRUE;
}
- HeapFree(ProcessHeap,
- 0,
- lpPartialStr);
+ LocalFree(lpPartialStr);
}
/* Display the list of services which need stopping */