olga / rpms / glibc

Forked from rpms/glibc 5 years ago
Clone

Blame SOURCES/glibc-rh677316-netdb-reentrant.patch

00db10
Backport of this upstream commit:
00db10
00db10
commit 7f9d00341057eb80b43fa83956b8d7798b4dabea
00db10
Author: Roland McGrath <roland@hack.frob.com>
00db10
Date:   Tue Aug 27 11:09:33 2013 -0700
00db10
00db10
    Clean up h_errno declaration to use __thread unconditionally.
00db10
00db10
Adjusted for the IS_IN changes, which were applied upstream after this
00db10
commit (and downstream before its backport).
00db10
00db10
diff --git a/include/netdb.h b/include/netdb.h
00db10
index 3b24747fd5df6562..b6d7b90bbf8abd2e 100644
00db10
--- a/include/netdb.h
00db10
+++ b/include/netdb.h
00db10
@@ -5,17 +5,12 @@
00db10
 /* Macros for accessing h_errno from inside libc.  */
00db10
 # if IS_IN_LIB
00db10
 #  undef  h_errno
00db10
-#  ifdef _LIBC_REENTRANT
00db10
-#   include <tls.h>
00db10
-#   if IS_IN (libc)
00db10
-#    define h_errno __libc_h_errno
00db10
-#   else
00db10
-#    define h_errno h_errno	/* For #ifndef h_errno tests.  */
00db10
-#   endif
00db10
-extern __thread int h_errno attribute_tls_model_ie;
00db10
+#  if IS_IN (libc)
00db10
+#   define h_errno __libc_h_errno
00db10
 #  else
00db10
-extern int h_errno;
00db10
-#  endif	/* _LIBC_REENTRANT */
00db10
+#   define h_errno h_errno	/* For #ifndef h_errno tests.  */
00db10
+#  endif
00db10
+extern __thread int h_errno attribute_tls_model_ie;
00db10
 # endif /* IS_IN_LIB */
00db10
 # define __set_h_errno(x) (h_errno = (x))
00db10