|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
Patch 71641-proper-errors-for-getaddrinfo-php55.patch for Streams related Bug #71641Patch version 2016-02-22 09:57 UTC Return to Bug #71641 | Download this patchThis patch is obsolete Obsoleted by patches:
Developer: torotil@gmail.com
diff --git a/main/network.c b/main/network.c
index 138f86b..dc33e81 100644
--- a/main/network.c
+++ b/main/network.c
@@ -107,9 +107,9 @@ const struct in6_addr in6addr_any = {0}; /* IN6ADDR_ANY_INIT; */
#if HAVE_GETADDRINFO
#ifdef HAVE_GAI_STRERROR
-# define PHP_GAI_STRERROR(x) (gai_strerror(x))
+# define PHP_GAI_STRERROR(x) (x == EIA_SYSTEM ? strerror(errno) : gai_strerror(x))
#else
-# define PHP_GAI_STRERROR(x) (php_gai_strerror(x))
+# define PHP_GAI_STRERROR(x) (x == EIA_SYSTEM ? strerror(errno) : php_gai_strerror(x))
/* {{{ php_gai_strerror
*/
static const char *php_gai_strerror(int code)
|
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Nov 05 14:00:01 2025 UTC |