From 062f7f4e193e9fe4861ab353ce414a7e96d65990 Mon Sep 17 00:00:00 2001 From: Francesco Chemolli Date: Tue, 13 Jul 2010 16:27:25 +0200 Subject: [PATCH] Reverted some changes from r10263 --- src/client_side_reply.cc | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/client_side_reply.cc b/src/client_side_reply.cc index 26043b9967..fdf3185069 100644 --- a/src/client_side_reply.cc +++ b/src/client_side_reply.cc @@ -1056,6 +1056,24 @@ clientReplyContext::storeNotOKTransferDone() const int clientHttpRequestStatus(int fd, ClientHttpRequest const *http) { +#if SIZEOF_INT64_T == 4 + if (http->out.size > 0x7FFF0000) { + debugs(88, 1, "WARNING: closing FD " << fd << " to prevent out.size counter overflow"); + debugs(88, 1, "\tclient " << http->getConn()->peer); + debugs(88, 1, "\treceived " << http->out.size << " bytes"); + debugs(88, 1, "\tURI " << http->log_uri); + return 1; + } + + if (http->out.offset > 0x7FFF0000) { + debugs(88, 1, "WARNING: closing FD " << fd < " to prevent out.offset counter overflow"); + debugs(88, 1, "\tclient " << http->getConn()->peer); + debugs(88, 1, "\treceived " << http->out.size << " bytes, offset " << http->out.offset); + debugs(88, 1, "\tURI " << http->log_uri); + return 1; + } + +#endif return 0; } -- 2.47.3