svn commit: samba r13880 - in branches/SAMBA_3_0/source/nmbd: .
jra at samba.org
jra at samba.org
Mon Mar 6 19:23:54 GMT 2006
Author: jra
Date: 2006-03-06 19:23:54 +0000 (Mon, 06 Mar 2006)
New Revision: 13880
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=13880
Log:
Fix coverity bug CID #97, mem leak on error path.
Jeremy.
Modified:
branches/SAMBA_3_0/source/nmbd/nmbd_winsproxy.c
Changeset:
Modified: branches/SAMBA_3_0/source/nmbd/nmbd_winsproxy.c
===================================================================
--- branches/SAMBA_3_0/source/nmbd/nmbd_winsproxy.c 2006-03-06 18:43:46 UTC (rev 13879)
+++ branches/SAMBA_3_0/source/nmbd/nmbd_winsproxy.c 2006-03-06 19:23:54 UTC (rev 13880)
@@ -85,6 +85,10 @@
nmbname->name_type, nb_flags, ttl,
WINS_PROXY_NAME, num_ips, iplist );
+ if(iplist != &ip) {
+ SAFE_FREE(iplist);
+ }
+
namerec = find_name_on_subnet(orig_broadcast_subnet, nmbname, FIND_ANY_NAME);
if (!namerec) {
DEBUG(0,("wins_proxy_name_query_request_success: failed to add "
@@ -94,10 +98,6 @@
return;
}
- if(iplist != &ip) {
- SAFE_FREE(iplist);
- }
-
/*
* Check that none of the IP addresses we are returning is on the
* same broadcast subnet as the original requesting packet. If it
More information about the samba-cvs
mailing list