about summary refs log tree commit diff
path: root/nss
diff options
context:
space:
mode:
Diffstat (limited to 'nss')
-rw-r--r--nss/getXXbyYY_r.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/nss/getXXbyYY_r.c b/nss/getXXbyYY_r.c
index 3f873a5fde..06f2abedd0 100644
--- a/nss/getXXbyYY_r.c
+++ b/nss/getXXbyYY_r.c
@@ -248,13 +248,12 @@ done:
   POSTPROCESS;
 #endif
   return (status == NSS_STATUS_SUCCESS ? 0
-	  : (status != NSS_STATUS_TRYAGAIN
 #ifdef NEED_H_ERRNO
-	     /* These functions only set errno if h_errno is
-		NETDB_INTERNAL.  */
-	     && *h_errnop == NETDB_INTERNAL
+	  /* These functions only set errno if h_errno is NETDB_INTERNAL.  */
+	  : status == NSS_STATUS_TRYAGAIN && *h_errnop != NETDB_INTERNAL
+	  ? EAGAIN
 #endif
-	     ? errno : EAGAIN));
+	  : errno);
 }