coar 97/08/17 17:12:24
Modified: src/modules/proxy proxy_util.c Log: Include the problem IP address and port in the error message when connect() fails. PR: 352 Reviewed by: Marc Slemko Revision Changes Path 1.23 +7 -2 apachen/src/modules/proxy/proxy_util.c Index: proxy_util.c =================================================================== RCS file: /export/home/cvs/apachen/src/modules/proxy/proxy_util.c,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- proxy_util.c 1997/07/27 03:13:34 1.22 +++ proxy_util.c 1997/08/18 00:12:23 1.23 @@ -1168,9 +1168,14 @@ errno = WSAGetLastError() - WSABASEERR; #endif /* WIN32 */ } while (i == -1 && errno == EINTR); - if (i == -1) proxy_log_uerror("connect", NULL, NULL, r->server); + if (i == -1) { + char details[128]; + + ap_snprintf(details, sizeof(details), "%s port %d", + inet_ntoa(addr->sin_addr), ntohs(addr->sin_port)); + proxy_log_uerror("connect", details, NULL, r->server); + } kill_timeout(r); return i; } -