mirror of
https://gitlab.isc.org/isc-projects/dhcp
synced 2025-08-29 13:28:14 +00:00
- A memory leak in the minires_nsendsigned() function call was repaired.
Effectively, this leaked ~80 bytes per DDNS update. [ISC-Bugs #16770]
This commit is contained in:
parent
75ab3070cc
commit
d69fb6a8d4
3
RELNOTES
3
RELNOTES
@ -195,6 +195,9 @@ the README file.
|
|||||||
|
|
||||||
- A reference leak on binding scopes set by ddns updates was repaired.
|
- A reference leak on binding scopes set by ddns updates was repaired.
|
||||||
|
|
||||||
|
- A memory leak in the minires_nsendsigned() function call was repaired.
|
||||||
|
Effectively, this leaked ~80 bytes per DDNS update.
|
||||||
|
|
||||||
Changes since 3.0.5rc1
|
Changes since 3.0.5rc1
|
||||||
|
|
||||||
- A bug was repaired in fixes to the dhclient, which sought to run the
|
- A bug was repaired in fixes to the dhclient, which sought to run the
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
|
* Copyright (c) 2004,2007 by Internet Systems Consortium, Inc. ("ISC")
|
||||||
* Copyright (c) 1995-2003 by Internet Software Consortium
|
* Copyright (c) 1995-2003 by Internet Software Consortium
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, and distribute this software for any
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
@ -67,8 +67,10 @@ res_nsendsigned(res_state statp,
|
|||||||
|
|
||||||
bufsize = msglen + 1024;
|
bufsize = msglen + 1024;
|
||||||
newmsg = (double *) malloc(bufsize);
|
newmsg = (double *) malloc(bufsize);
|
||||||
if (newmsg == NULL)
|
if (newmsg == NULL) {
|
||||||
|
free(nstatp);
|
||||||
return ISC_R_NOMEMORY;
|
return ISC_R_NOMEMORY;
|
||||||
|
}
|
||||||
memcpy(newmsg, msg, msglen);
|
memcpy(newmsg, msg, msglen);
|
||||||
newmsglen = msglen;
|
newmsglen = msglen;
|
||||||
|
|
||||||
@ -91,6 +93,7 @@ res_nsendsigned(res_state statp,
|
|||||||
NOERROR, dstkey, NULL, 0,
|
NOERROR, dstkey, NULL, 0,
|
||||||
sig, &siglen, 0);
|
sig, &siglen, 0);
|
||||||
if (rcode != ISC_R_SUCCESS) {
|
if (rcode != ISC_R_SUCCESS) {
|
||||||
|
dst_free_key(dstkey);
|
||||||
free (nstatp);
|
free (nstatp);
|
||||||
free (newmsg);
|
free (newmsg);
|
||||||
return rcode;
|
return rcode;
|
||||||
@ -107,6 +110,7 @@ retry:
|
|||||||
|
|
||||||
rcode = res_nsend(nstatp, newmsg, newmsglen, answer, anslen, &ret);
|
rcode = res_nsend(nstatp, newmsg, newmsglen, answer, anslen, &ret);
|
||||||
if (rcode != ISC_R_SUCCESS) {
|
if (rcode != ISC_R_SUCCESS) {
|
||||||
|
dst_free_key(dstkey);
|
||||||
free (nstatp);
|
free (nstatp);
|
||||||
free (newmsg);
|
free (newmsg);
|
||||||
return rcode;
|
return rcode;
|
||||||
@ -119,6 +123,7 @@ retry:
|
|||||||
if (rcode != ISC_R_SUCCESS) {
|
if (rcode != ISC_R_SUCCESS) {
|
||||||
Dprint(nstatp->pfcode & RES_PRF_REPLY,
|
Dprint(nstatp->pfcode & RES_PRF_REPLY,
|
||||||
(stdout, ";; TSIG invalid (%s)\n", p_rcode(ret)));
|
(stdout, ";; TSIG invalid (%s)\n", p_rcode(ret)));
|
||||||
|
dst_free_key(dstkey);
|
||||||
free (nstatp);
|
free (nstatp);
|
||||||
free (newmsg);
|
free (newmsg);
|
||||||
return rcode;
|
return rcode;
|
||||||
@ -132,6 +137,7 @@ retry:
|
|||||||
goto retry;
|
goto retry;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
dst_free_key(dstkey);
|
||||||
free (nstatp);
|
free (nstatp);
|
||||||
free (newmsg);
|
free (newmsg);
|
||||||
*anssize = anslen;
|
*anssize = anslen;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user