ENSURE that a message's memory pools don't have any allocated data at the

end of msgreset().  This should trigger the mpctx->allocated != 0 assertion
when the leak occurs, not at server shutdown.
This commit is contained in:
Brian Wellington 2001-02-18 23:46:26 +00:00
parent 50448dc92a
commit 3bd43bb300

View file

@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: message.c,v 1.178 2001/02/15 19:09:55 gson Exp $ */
/* $Id: message.c,v 1.179 2001/02/18 23:46:26 bwelling Exp $ */
/***
*** Imports
@ -628,6 +628,9 @@ msgreset(dns_message_t *msg, isc_boolean_t everything) {
*/
if (!everything)
msginit(msg);
ENSURE(isc_mempool_getallocated(msg->namepool) == 0);
ENSURE(isc_mempool_getallocated(msg->rdspool) == 0);
}
static unsigned int