From: wessels <> Date: Sat, 25 Oct 1997 00:10:36 +0000 (+0000) Subject: err->errno --> err->xerrno X-Git-Tag: SQUID_3_0_PRE1~4695 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c45ed9ad4f1a16c723ba195d919eac64753b09e9;p=thirdparty%2Fsquid.git err->errno --> err->xerrno --- diff --git a/src/errorpage.cc b/src/errorpage.cc index 12b24c43dd..276d5f546d 100644 --- a/src/errorpage.cc +++ b/src/errorpage.cc @@ -1,6 +1,6 @@ /* - * $Id: errorpage.cc,v 1.83 1997/10/21 17:21:32 kostas Exp $ + * $Id: errorpage.cc,v 1.84 1997/10/24 18:10:36 wessels Exp $ * * DEBUG: section 4 Error Generation * AUTHOR: Duane Wessels @@ -130,11 +130,11 @@ errorConvert(char token, ErrorState * err) p = "UNKNOWN\n"; break; case 'e': - snprintf(buf, CVT_BUF_SZ, "%d", err->errno); + snprintf(buf, CVT_BUF_SZ, "%d", err->xerrno); p = buf; break; case 'E': - snprintf(buf, CVT_BUF_SZ, "(%d) %s", err->errno, strerror(err->errno)); + snprintf(buf, CVT_BUF_SZ, "(%d) %s", err->xerrno, strerror(err->xerrno)); p = buf; break; case 'w': diff --git a/src/ftp.cc b/src/ftp.cc index 9de60d67ed..f715f1496a 100644 --- a/src/ftp.cc +++ b/src/ftp.cc @@ -1,6 +1,6 @@ /* - * $Id: ftp.cc,v 1.148 1997/10/24 03:14:37 wessels Exp $ + * $Id: ftp.cc,v 1.149 1997/10/24 18:10:37 wessels Exp $ * * DEBUG: section 9 File Transfer Protocol (FTP) * AUTHOR: Harvest Derived @@ -649,7 +649,7 @@ ftpReadData(int fd, void *data) if (entry->mem_obj->inmem_hi == 0) { err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_READ_ERROR; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_INTERNAL_SERVER_ERROR; err->request = requestLink(ftpState->request); errorAppendEntry(entry, err); @@ -660,7 +660,7 @@ ftpReadData(int fd, void *data) } else if (len == 0 && entry->mem_obj->inmem_hi == 0) { err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_ZERO_SIZE_OBJECT; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_SERVICE_UNAVAILABLE; err->request = requestLink(ftpState->request); errorAppendEntry(entry, err); @@ -872,7 +872,7 @@ ftpStart(request_t * request, StoreEntry * entry) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_SOCKET_FAILURE; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(ftpState->request); errorAppendEntry(entry, err); storeAbort(entry, 0); @@ -910,7 +910,7 @@ ftpConnectDone(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(request->host); err->port = request->port; err->request = requestLink(request); @@ -963,7 +963,7 @@ ftpWriteCommandCallback(int fd, char *buf, int size, int errflag, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_WRITE_ERROR; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(ftpState->request); errorAppendEntry(entry, err); } @@ -1042,7 +1042,7 @@ ftpReadControlReply(int fd, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_READ_ERROR; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(ftpState->request); errorAppendEntry(entry, err); } @@ -1060,7 +1060,7 @@ ftpReadControlReply(int fd, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_READ_ERROR; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(ftpState->request); errorAppendEntry(entry, err); } @@ -1357,7 +1357,7 @@ ftpPasvCallback(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(ftpState->data.host); err->port = ftpState->data.port; err->request = requestLink(request); diff --git a/src/gopher.cc b/src/gopher.cc index 4935eff45d..041023d0d1 100644 --- a/src/gopher.cc +++ b/src/gopher.cc @@ -1,6 +1,6 @@ /* - * $Id: gopher.cc,v 1.102 1997/10/23 16:38:10 wessels Exp $ + * $Id: gopher.cc,v 1.103 1997/10/24 18:10:38 wessels Exp $ * * DEBUG: section 10 Gopher * AUTHOR: Harvest Derived @@ -711,7 +711,7 @@ gopherReadReply(int fd, void *data) ErrorState *err; err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_READ_ERROR; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_INTERNAL_SERVER_ERROR; err->url = entry->url; errorAppendEntry(entry, err); @@ -723,7 +723,7 @@ gopherReadReply(int fd, void *data) ErrorState *err; err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_ZERO_SIZE_OBJECT; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_SERVICE_UNAVAILABLE; err->url = gopherState->request; errorAppendEntry(entry, err); @@ -767,7 +767,7 @@ gopherSendComplete(int fd, char *buf, int size, int errflag, void *data) ErrorState *err; err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(gopherState->host); err->port = gopherState->port; err->http_status = HTTP_SERVICE_UNAVAILABLE; @@ -880,7 +880,7 @@ gopherStart(StoreEntry * entry) /* was assert */ err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_SOCKET_FAILURE; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_INTERNAL_SERVER_ERROR; if (entry && entry->url) err->url = entry->url; @@ -943,7 +943,7 @@ gopherConnectDone(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(gopherState->host); err->port = gopherState->port; err->url = entry->url; diff --git a/src/http.cc b/src/http.cc index 138b38128d..be01732a7f 100644 --- a/src/http.cc +++ b/src/http.cc @@ -1,6 +1,6 @@ /* - * $Id: http.cc,v 1.198 1997/10/23 23:27:19 wessels Exp $ + * $Id: http.cc,v 1.199 1997/10/24 18:10:39 wessels Exp $ * * DEBUG: section 11 Hypertext Transfer Protocol (HTTP) * AUTHOR: Harvest Derived @@ -637,7 +637,7 @@ httpReadReply(int fd, void *data) if (clen == 0) { err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_READ_ERROR; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_INTERNAL_SERVER_ERROR; err->request = requestLink(httpState->request); errorAppendEntry(entry, err); @@ -654,7 +654,7 @@ httpReadReply(int fd, void *data) httpState->eof = 1; err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_ZERO_SIZE_OBJECT; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_SERVICE_UNAVAILABLE; err->request = requestLink(httpState->request); errorAppendEntry(entry, err); @@ -703,7 +703,7 @@ httpSendComplete(int fd, char *buf, int size, int errflag, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_WRITE_ERROR; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(httpState->request); errorAppendEntry(entry, err); storeAbort(entry, 0); @@ -953,7 +953,7 @@ httpSocketOpen(StoreEntry * entry, request_t * request) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_SOCKET_FAILURE; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; if (request) err->request = requestLink(request); errorAppendEntry(entry, err); @@ -1082,7 +1082,7 @@ httpConnectDone(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(request->host); err->port = request->port; err->request = requestLink(request); diff --git a/src/ssl.cc b/src/ssl.cc index 1ea6c06c19..5812ba6092 100644 --- a/src/ssl.cc +++ b/src/ssl.cc @@ -1,6 +1,6 @@ /* - * $Id: ssl.cc,v 1.63 1997/10/20 19:25:22 wessels Exp $ + * $Id: ssl.cc,v 1.64 1997/10/24 18:10:40 wessels Exp $ * * DEBUG: section 26 Secure Sockets Layer Proxy * AUTHOR: Duane Wessels @@ -334,7 +334,7 @@ sslConnectDone(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(sslState->host); err->port = sslState->port; err->request = requestLink(request); @@ -370,7 +370,7 @@ sslStart(int fd, const char *url, request_t * request, size_t * size_ptr) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_SOCKET_FAILURE; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(request); errorSend(fd, err); return; diff --git a/src/structs.h b/src/structs.h index 77a97ac832..9ee2bd6fb2 100644 --- a/src/structs.h +++ b/src/structs.h @@ -855,7 +855,7 @@ struct _ErrorState { http_status http_status; request_t *request; char *url; - int errno; + int xerrno; char *host; u_short port; char *dnsserver_msg; diff --git a/src/tunnel.cc b/src/tunnel.cc index 0487e5aac1..a103db72dc 100644 --- a/src/tunnel.cc +++ b/src/tunnel.cc @@ -1,6 +1,6 @@ /* - * $Id: tunnel.cc,v 1.63 1997/10/20 19:25:22 wessels Exp $ + * $Id: tunnel.cc,v 1.64 1997/10/24 18:10:40 wessels Exp $ * * DEBUG: section 26 Secure Sockets Layer Proxy * AUTHOR: Duane Wessels @@ -334,7 +334,7 @@ sslConnectDone(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(sslState->host); err->port = sslState->port; err->request = requestLink(request); @@ -370,7 +370,7 @@ sslStart(int fd, const char *url, request_t * request, size_t * size_ptr) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_SOCKET_FAILURE; err->http_status = HTTP_INTERNAL_SERVER_ERROR; - err->errno = errno; + err->xerrno = errno; err->request = requestLink(request); errorSend(fd, err); return; diff --git a/src/wais.cc b/src/wais.cc index 8f214fa745..3b8abb8bcf 100644 --- a/src/wais.cc +++ b/src/wais.cc @@ -1,6 +1,6 @@ /* - * $Id: wais.cc,v 1.88 1997/10/23 16:38:16 wessels Exp $ + * $Id: wais.cc,v 1.89 1997/10/24 18:10:41 wessels Exp $ * * DEBUG: section 24 WAIS Relay * AUTHOR: Harvest Derived @@ -219,7 +219,7 @@ waisReadReply(int fd, void *data) ErrorState *err; err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_ZERO_SIZE_OBJECT; - err->errno = errno; + err->xerrno = errno; err->http_status = HTTP_SERVICE_UNAVAILABLE; err->request = urlParse(METHOD_CONNECT, waisState->request); errorAppendEntry(entry, err); @@ -253,7 +253,7 @@ waisSendComplete(int fd, char *buf, int size, int errflag, void *data) ErrorState *err; err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(waisState->relayhost); err->port = waisState->relayport; err->http_status = HTTP_SERVICE_UNAVAILABLE; @@ -387,7 +387,7 @@ waisConnectDone(int fd, int status, void *data) err = xcalloc(1, sizeof(ErrorState)); err->type = ERR_CONNECT_FAIL; err->http_status = HTTP_SERVICE_UNAVAILABLE; - err->errno = errno; + err->xerrno = errno; err->host = xstrdup(waisState->relayhost); err->port = waisState->relayport; err->request = urlParse(METHOD_CONNECT, request);