Module Name:    src
Committed By:   christos
Date:           Mon Aug 13 08:48:46 UTC 2018

Modified Files:
        src/external/mpl/bind/dist/lib/isc/unix: socket.c

Log Message:
Make ENOBUFS a soft error


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/mpl/bind/dist/lib/isc/unix/socket.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/mpl/bind/dist/lib/isc/unix/socket.c
diff -u src/external/mpl/bind/dist/lib/isc/unix/socket.c:1.2 src/external/mpl/bind/dist/lib/isc/unix/socket.c:1.3
--- src/external/mpl/bind/dist/lib/isc/unix/socket.c:1.2	Sun Aug 12 09:02:39 2018
+++ src/external/mpl/bind/dist/lib/isc/unix/socket.c	Mon Aug 13 04:48:46 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: socket.c,v 1.2 2018/08/12 13:02:39 christos Exp $	*/
+/*	$NetBSD: socket.c,v 1.3 2018/08/13 08:48:46 christos Exp $	*/
 
 /*
  * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
@@ -258,6 +258,7 @@ typedef enum { poll_idle, poll_active, p
 #define SOFT_ERROR(e)	((e) == EAGAIN || \
 			 (e) == EWOULDBLOCK || \
 			 (e) == EINTR || \
+			 (e) == ENOBUFS || \
 			 (e) == 0)
 
 #define DLVL(x) ISC_LOGCATEGORY_GENERAL, ISC_LOGMODULE_SOCKET, ISC_LOG_DEBUG(x)
@@ -1953,7 +1954,7 @@ doio_recv(isc__socket_t *sock, isc_socke
 		SOFT_OR_HARD(EHOSTDOWN, ISC_R_HOSTDOWN);
 		/* HPUX 11.11 can return EADDRNOTAVAIL. */
 		SOFT_OR_HARD(EADDRNOTAVAIL, ISC_R_ADDRNOTAVAIL);
-		ALWAYS_HARD(ENOBUFS, ISC_R_NORESOURCES);
+		SOFT_OR_HARD(ENOBUFS, ISC_R_NORESOURCES);
 		/* Should never get this one but it was seen. */
 #ifdef ENOPROTOOPT
 		SOFT_OR_HARD(ENOPROTOOPT, ISC_R_HOSTUNREACH);
@@ -2150,7 +2151,7 @@ doio_send(isc__socket_t *sock, isc_socke
 		ALWAYS_HARD(EHOSTDOWN, ISC_R_HOSTUNREACH);
 #endif
 		ALWAYS_HARD(ENETUNREACH, ISC_R_NETUNREACH);
-		ALWAYS_HARD(ENOBUFS, ISC_R_NORESOURCES);
+		SOFT_OR_HARD(ENOBUFS, ISC_R_NORESOURCES);
 		ALWAYS_HARD(EPERM, ISC_R_HOSTUNREACH);
 		ALWAYS_HARD(EPIPE, ISC_R_NOTCONNECTED);
 		ALWAYS_HARD(ECONNRESET, ISC_R_CONNECTIONRESET);

Reply via email to