mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-03 16:15:27 +00:00
1845. [bug] Improve error reporting to distingish between
accept()/fcntl() and socket()/fcntl() errors. [RT #13745]
This commit is contained in:
4
CHANGES
4
CHANGES
@@ -39,7 +39,9 @@
|
|||||||
1846. [contrib] query-loc-0.3.0 from Stephane Bortzmeyer
|
1846. [contrib] query-loc-0.3.0 from Stephane Bortzmeyer
|
||||||
<bortzmeyer@nic.fr>.
|
<bortzmeyer@nic.fr>.
|
||||||
|
|
||||||
1845. [placeholder] rt13745
|
1845. [bug] Improve error reporting to distingish between
|
||||||
|
accept()/fcntl() and socket()/fcntl() errors.
|
||||||
|
[RT #13745]
|
||||||
|
|
||||||
1844. [bug] inet_pton() accepted more that 4 hexadecimal digits
|
1844. [bug] inet_pton() accepted more that 4 hexadecimal digits
|
||||||
for each 16 bit piece of the IPv6 address. The text
|
for each 16 bit piece of the IPv6 address. The text
|
||||||
|
@@ -34,7 +34,7 @@ rt13662 new
|
|||||||
rt13694 new
|
rt13694 new
|
||||||
rt13707 new
|
rt13707 new
|
||||||
rt13714 new
|
rt13714 new
|
||||||
rt13745 new
|
rt13745 closed
|
||||||
rt13753 new
|
rt13753 new
|
||||||
rt13754 new
|
rt13754 new
|
||||||
rt13771 new
|
rt13771 new
|
||||||
|
@@ -15,7 +15,7 @@
|
|||||||
* PERFORMANCE OF THIS SOFTWARE.
|
* PERFORMANCE OF THIS SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* $Id: socket.c,v 1.249 2005/04/27 04:57:23 sra Exp $ */
|
/* $Id: socket.c,v 1.250 2005/05/19 02:42:42 marka Exp $ */
|
||||||
|
|
||||||
/*! \file */
|
/*! \file */
|
||||||
|
|
||||||
@@ -1358,6 +1358,7 @@ isc_socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type,
|
|||||||
int on = 1;
|
int on = 1;
|
||||||
#endif
|
#endif
|
||||||
char strbuf[ISC_STRERRORSIZE];
|
char strbuf[ISC_STRERRORSIZE];
|
||||||
|
const char *err = "socket";
|
||||||
|
|
||||||
REQUIRE(VALID_MANAGER(manager));
|
REQUIRE(VALID_MANAGER(manager));
|
||||||
REQUIRE(socketp != NULL && *socketp == NULL);
|
REQUIRE(socketp != NULL && *socketp == NULL);
|
||||||
@@ -1390,6 +1391,7 @@ isc_socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type,
|
|||||||
(void)close(sock->fd);
|
(void)close(sock->fd);
|
||||||
errno = tmp;
|
errno = tmp;
|
||||||
sock->fd = new;
|
sock->fd = new;
|
||||||
|
err = "isc_socket_create: fcntl";
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -1426,7 +1428,7 @@ isc_socket_create(isc_socketmgr_t *manager, int pf, isc_sockettype_t type,
|
|||||||
default:
|
default:
|
||||||
isc__strerror(errno, strbuf, sizeof(strbuf));
|
isc__strerror(errno, strbuf, sizeof(strbuf));
|
||||||
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
||||||
"socket() %s: %s",
|
"%s() %s: %s", err,
|
||||||
isc_msgcat_get(isc_msgcat,
|
isc_msgcat_get(isc_msgcat,
|
||||||
ISC_MSGSET_GENERAL,
|
ISC_MSGSET_GENERAL,
|
||||||
ISC_MSG_FAILED,
|
ISC_MSG_FAILED,
|
||||||
@@ -1778,6 +1780,7 @@ internal_accept(isc_task_t *me, isc_event_t *ev) {
|
|||||||
int fd;
|
int fd;
|
||||||
isc_result_t result = ISC_R_SUCCESS;
|
isc_result_t result = ISC_R_SUCCESS;
|
||||||
char strbuf[ISC_STRERRORSIZE];
|
char strbuf[ISC_STRERRORSIZE];
|
||||||
|
const char *err = "accept";
|
||||||
|
|
||||||
UNUSED(me);
|
UNUSED(me);
|
||||||
|
|
||||||
@@ -1841,6 +1844,7 @@ internal_accept(isc_task_t *me, isc_event_t *ev) {
|
|||||||
(void)close(fd);
|
(void)close(fd);
|
||||||
errno = tmp;
|
errno = tmp;
|
||||||
fd = new;
|
fd = new;
|
||||||
|
err = "fcntl";
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -1870,7 +1874,7 @@ internal_accept(isc_task_t *me, isc_event_t *ev) {
|
|||||||
}
|
}
|
||||||
isc__strerror(errno, strbuf, sizeof(strbuf));
|
isc__strerror(errno, strbuf, sizeof(strbuf));
|
||||||
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
||||||
"internal_accept: accept() %s: %s",
|
"internal_accept: %s() %s: %s", err,
|
||||||
isc_msgcat_get(isc_msgcat,
|
isc_msgcat_get(isc_msgcat,
|
||||||
ISC_MSGSET_GENERAL,
|
ISC_MSGSET_GENERAL,
|
||||||
ISC_MSG_FAILED,
|
ISC_MSG_FAILED,
|
||||||
|
Reference in New Issue
Block a user