- all those macros may conflict
authorMichael Wallner <mike@php.net>
Tue, 6 Sep 2005 11:47:57 +0000 (11:47 +0000)
committerMichael Wallner <mike@php.net>
Tue, 6 Sep 2005 11:47:57 +0000 (11:47 +0000)
http_request_pool_api.c

index 41352b586ad48e54d2d9b2f2108a510f3478f7ac..282fda9ed2df25b2becac2c64ccd09e617642fb0 100644 (file)
@@ -186,7 +186,11 @@ PHP_HTTP_API STATUS _http_request_pool_send(http_request_pool *pool TSRMLS_DC)
                fprintf(stderr, "> %d unfinished requests of pool %p remaining\n", pool->unfinished, pool);
 #endif
                if (SUCCESS != http_request_pool_select(pool)) {
-                       http_error(HE_WARNING, HTTP_E_SOCKET, "Socket error");
+#ifdef PHP_WIN32
+                       http_error(HE_WARNING, HTTP_E_SOCKET, WSAGetLastError());
+#else
+                       http_error(HE_WARNING, HTTP_E_SOCKET, strerror(errno));
+#endif
                        return FAILURE;
                }
        }