summaryrefslogtreecommitdiff
path: root/source3/nmbd
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2006-03-06 19:30:34 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:10:58 -0500
commit4c0bf8d75dcaca833da2bc8b284d4ddf1d698f64 (patch)
tree84f5eaa5adadf82b8ba39f2f1d10405c09e2d184 /source3/nmbd
parent9bb215fe68c2b6e1bbc90748ad28d3ba9491e4ac (diff)
downloadsamba-4c0bf8d75dcaca833da2bc8b284d4ddf1d698f64.tar.gz
samba-4c0bf8d75dcaca833da2bc8b284d4ddf1d698f64.tar.bz2
samba-4c0bf8d75dcaca833da2bc8b284d4ddf1d698f64.zip
r13884: Fix coverity CID #95. Resource leak on error path.
Jeremy. (This used to be commit f4bf550b5757024b41062784b185b52a1a0e11f4)
Diffstat (limited to 'source3/nmbd')
-rw-r--r--source3/nmbd/nmbd_packets.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/nmbd/nmbd_packets.c b/source3/nmbd/nmbd_packets.c
index c25473c4fb..0f84b4f771 100644
--- a/source3/nmbd/nmbd_packets.c
+++ b/source3/nmbd/nmbd_packets.c
@@ -536,6 +536,8 @@ void queue_wins_refresh(struct nmb_name *nmbname,
userdata = (struct userdata_struct *)SMB_MALLOC(sizeof(*userdata) + strlen(tag) + 1);
if (!userdata) {
+ p->locked = False;
+ free_packet(p);
DEBUG(0,("Failed to allocate userdata structure!\n"));
return;
}