summaryrefslogtreecommitdiff
path: root/source3/wrepld/process.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/wrepld/process.c')
-rw-r--r--source3/wrepld/process.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source3/wrepld/process.c b/source3/wrepld/process.c
index 56013d2e17..aca0500614 100644
--- a/source3/wrepld/process.c
+++ b/source3/wrepld/process.c
@@ -540,6 +540,7 @@ static void send_entry_request(GENERIC_PACKET *q, GENERIC_PACKET *r)
/* Allocate the space for the ip_list. */
if((ip_list = (struct in_addr *)talloc(mem_ctx, num_ips * sizeof(struct in_addr))) == NULL) {
+ SAFE_FREE(dbuf.dptr);
DEBUG(0,("initialise_wins: talloc fail !\n"));
return;
}
@@ -549,6 +550,8 @@ static void send_entry_request(GENERIC_PACKET *q, GENERIC_PACKET *r)
ip_list[i] = *interpret_addr2(ip_str);
}
+ SAFE_FREE(dbuf.dptr);
+
/* add all entries that have 60 seconds or more to live */
if ((ttl - 60) > time_now || ttl == PERMANENT_TTL) {
if(ttl != PERMANENT_TTL)