BIND 8.2.3 REL Memory Leak
kevind at sea.checkpoint.com
kevind at sea.checkpoint.com
Thu Apr 19 17:56:05 UTC 2001
I am seeing a memory leak in BIND 8.2.3 REL
The leak happens when named is processing DDNS update packets.
When building with -DMEMCLUSTER_RECORD & -DRECORD_STRINGS
I am seeing about two leaks per DDNS update. Here is what I am seeing
at the bottom of named.memstats after doing an add and delete of a name:
Active Memory:
db_save.c:142 15daf4:32
db_save.c:142 15dabc:32
db_save.c:142 15da84:32
db_save.c:142 151f14:36
Looking at named.run, I can trace these savedata() calls to line 1337 in
ns_update.c
For some reason these databuf's are getting lost and never freed.
I would expect them to get freed when free_rrecp() is called in res_update().
They are not. When add a call to free_rrecp() at the bottom of
req_update_private() just before the return(Finish) the databuf's get freed
and
there is no longer a memory leak. This does not seem like the proper fix.
Can anyone have a better fix?
Attach is a context diff.
-Kevin
Index: ns_update.c
===================================================================
RCS file: /proj/cvs/isc/bind/src/bin/named/ns_update.c,v
retrieving revision 8.91
diff -c -r8.91 ns_update.c
*** ns_update.c 2001/03/12 01:49:00 8.91
--- ns_update.c 2001/04/19 17:46:06
***************
*** 1373,1378 ****
--- 1373,1380 ----
/* Make a log of the update. */
(void) printupdatelog(from, &curupd, hp, zp, old_serial);
+ free_rrecp(&curupd, 0, from);
+
return (Finish);
}
More information about the bind-workers
mailing list