summaryrefslogtreecommitdiff
path: root/source3/nmbd
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2006-06-28 20:39:07 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:19:05 -0500
commit79eaa709a05d765673ea0766b1d23a0c60d76b4c (patch)
tree682ccda72b1158de3fbd12d1d1a1a3c2342bb2b3 /source3/nmbd
parentb2ddb4626c786fda53dc2bb0c1ec1b8d72c15b40 (diff)
downloadsamba-79eaa709a05d765673ea0766b1d23a0c60d76b4c.tar.gz
samba-79eaa709a05d765673ea0766b1d23a0c60d76b4c.tar.bz2
samba-79eaa709a05d765673ea0766b1d23a0c60d76b4c.zip
r16642: Fix show-stopper bug #3876. Double-free in wins
server code. Jerry please merge for 3.0.23. Jeremy. (This used to be commit d354b430ff0473764db8ea492a68d10946dadc23)
Diffstat (limited to 'source3/nmbd')
-rw-r--r--source3/nmbd/nmbd_winsserver.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/nmbd/nmbd_winsserver.c b/source3/nmbd/nmbd_winsserver.c
index 29d5c41de8..86f7fd5850 100644
--- a/source3/nmbd/nmbd_winsserver.c
+++ b/source3/nmbd/nmbd_winsserver.c
@@ -76,6 +76,7 @@ static struct name_record *wins_record_to_name_record(TDB_DATA key, TDB_DATA dat
if (!namerec) {
return NULL;
}
+ ZERO_STRUCTP(namerec);
namerec->data.ip = SMB_MALLOC_ARRAY(struct in_addr, num_ips);
if (!namerec->data.ip) {
@@ -294,7 +295,6 @@ BOOL remove_name_from_wins_namelist(struct name_record *namerec)
ret = tdb_delete(wins_tdb, key);
DLIST_REMOVE(wins_server_subnet->namelist, namerec);
- SAFE_FREE(namerec->data.ip);
/* namerec must be freed by the caller */