2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 13:38:26 +00:00

init the name in dns_message_gettempname(). This means it'll be done twice

in many cases, but it means dns_message_puttempname() can safely be called
on the name in all cases.
This commit is contained in:
Brian Wellington 2001-03-15 03:00:50 +00:00
parent 2048bb8c0c
commit fc0d37fa3a

View File

@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: message.c,v 1.185 2001/03/05 21:15:41 bwelling Exp $ */
/* $Id: message.c,v 1.186 2001/03/15 03:00:50 bwelling Exp $ */
/***
*** Imports
@ -2143,6 +2143,7 @@ dns_message_gettempname(dns_message_t *msg, dns_name_t **item) {
*item = isc_mempool_get(msg->namepool);
if (*item == NULL)
return (ISC_R_NOMEMORY);
dns_name_init(*item, NULL);
return (ISC_R_SUCCESS);
}