Author: gschneider
Date: Sat Nov 29 14:30:18 2008
New Revision: 37744
URL:
http://svn.reactos.org/svn/reactos?rev=37744&view=rev
Log:
- Fix two possible memory leaks by freeing resources
- Patch by Daniel Zimmermann, <netzimme AT aim DOT com>
- Bug #3911, CIDs 607 and 608
Modified:
trunk/reactos/base/applications/network/net/cmdStop.c
trunk/reactos/base/applications/network/net/cmdstart.c
Modified: trunk/reactos/base/applications/network/net/cmdStop.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/network/…
==============================================================================
--- trunk/reactos/base/applications/network/net/cmdStop.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/network/net/cmdStop.c [iso-8859-1] Sat Nov 29 14:30:18
2008
@@ -83,6 +83,7 @@
row = (CHAR *) malloc(row_size*sizeof(CHAR));
if (row == NULL)
{
+ free(srvlst);
return 0;
}
memset(row,0,row_size*sizeof(CHAR));
Modified: trunk/reactos/base/applications/network/net/cmdstart.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/applications/network/…
==============================================================================
--- trunk/reactos/base/applications/network/net/cmdstart.c [iso-8859-1] (original)
+++ trunk/reactos/base/applications/network/net/cmdstart.c [iso-8859-1] Sat Nov 29
14:30:18 2008
@@ -83,6 +83,7 @@
row = (CHAR *) malloc(row_size*sizeof(CHAR));
if (row == NULL)
{
+ free(srvlst);
return 0;
}
memset(row,0,row_size*sizeof(CHAR));