From: wessels <> Date: Sat, 6 Apr 1996 00:22:19 +0000 (+0000) Subject: remove some #ifdef'd-out pieces of code X-Git-Tag: SQUID_3_0_PRE1~6274 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=14e59844bf5fe01b2f330e3d4cbfd415267f35e5;p=thirdparty%2Fsquid.git remove some #ifdef'd-out pieces of code --- diff --git a/src/gopher.cc b/src/gopher.cc index 8f9737c7d5..e716a209f1 100644 --- a/src/gopher.cc +++ b/src/gopher.cc @@ -1,4 +1,4 @@ -/* $Id: gopher.cc,v 1.15 1996/04/04 18:41:25 wessels Exp $ */ +/* $Id: gopher.cc,v 1.16 1996/04/05 17:22:19 wessels Exp $ */ /* * DEBUG: Section 10 gopher: GOPHER @@ -634,20 +634,12 @@ int gopherReadReply(fd, data) COMM_SELECT_READ, (PF) gopherReadReply, (caddr_t) data); -/* don't install read timeout until we are below the GAP */ -#ifdef INSTALL_READ_TIMEOUT_ABOVE_GAP - comm_set_select_handler_plus_timeout(fd, - COMM_SELECT_TIMEOUT, - (PF) gopherReadReplyTimeout, - (caddr_t) data, - getReadTimeout()); -#else + /* don't install read timeout until we are below the GAP */ comm_set_select_handler_plus_timeout(fd, COMM_SELECT_TIMEOUT, (PF) NULL, (caddr_t) NULL, (time_t) 0); -#endif comm_set_stall(fd, getStallDelay()); /* dont try reading again for a while */ return 0; } diff --git a/src/http.cc b/src/http.cc index c34368bcb1..4f10143c0f 100644 --- a/src/http.cc +++ b/src/http.cc @@ -1,4 +1,4 @@ -/* $Id: http.cc,v 1.29 1996/04/05 16:57:26 wessels Exp $ */ +/* $Id: http.cc,v 1.30 1996/04/05 17:22:20 wessels Exp $ */ /* * DEBUG: Section 11 http: HTTP @@ -119,14 +119,6 @@ static void httpReadReplyTimeout(fd, data) entry = data->entry; debug(11, 4, "httpReadReplyTimeout: FD %d: \n", fd, entry->url); cached_error_entry(entry, ERR_READ_TIMEOUT, NULL); -#ifdef NOW_DONE_IN_CLOSE_AND_FREE - if (data->icp_rwd_ptr) - safe_free(data->icp_rwd_ptr); - if (data->icp_page_ptr) { - put_free_8k_page(data->icp_page_ptr, __FILE__, __LINE__); - data->icp_page_ptr = NULL; - } -#endif comm_set_select_handler(fd, COMM_SELECT_READ, 0, 0); httpCloseAndFree(fd, data); } @@ -142,14 +134,6 @@ static void httpLifetimeExpire(fd, data) debug(11, 4, "httpLifeTimeExpire: FD %d: \n", fd, entry->url); cached_error_entry(entry, ERR_LIFETIME_EXP, NULL); -#ifdef NOW_DONE_IN_CLOSE_AND_FREE - if (data->icp_page_ptr) { - put_free_8k_page(data->icp_page_ptr, __FILE__, __LINE__); - data->icp_page_ptr = NULL; - } - if (data->icp_rwd_ptr) - safe_free(data->icp_rwd_ptr); -#endif comm_set_select_handler(fd, COMM_SELECT_READ | COMM_SELECT_WRITE, 0, 0); httpCloseAndFree(fd, data); } @@ -298,21 +282,14 @@ static void httpReadReply(fd, data) COMM_SELECT_READ, (PF) httpReadReply, (caddr_t) data); -/* don't install read timeout until we are below the GAP */ -#ifdef INSTALL_READ_TIMEOUT_ABOVE_GAP - comm_set_select_handler_plus_timeout(fd, - COMM_SELECT_TIMEOUT, - (PF) httpReadReplyTimeout, - (caddr_t) data, - getReadTimeout()); -#else + /* don't install read timeout until we are below the GAP */ comm_set_select_handler_plus_timeout(fd, COMM_SELECT_TIMEOUT, (PF) NULL, (caddr_t) NULL, (time_t) 0); -#endif - comm_set_stall(fd, getStallDelay()); /* dont try reading again for a while */ + /* dont try reading again for a while */ + comm_set_stall(fd, getStallDelay()); return; } } else { @@ -494,7 +471,12 @@ static void httpSendRequest(fd, data) xfree(post_buf); } debug(11, 6, "httpSendRequest: FD %d: buf '%s'\n", fd, buf); - data->icp_rwd_ptr = icpWrite(fd, buf, len, 30, httpSendComplete, (caddr_t) data); + data->icp_rwd_ptr = icpWrite(fd, + buf, + len, + 30, + httpSendComplete, + (caddr_t) data); } static void httpConnInProgress(fd, data) diff --git a/src/wais.cc b/src/wais.cc index 17cd8da8ca..8652cd433a 100644 --- a/src/wais.cc +++ b/src/wais.cc @@ -1,4 +1,4 @@ -/* $Id: wais.cc,v 1.17 1996/04/04 01:30:54 wessels Exp $ */ +/* $Id: wais.cc,v 1.18 1996/04/05 17:22:22 wessels Exp $ */ /* * DEBUG: Section 24 wais @@ -101,19 +101,12 @@ void waisReadReply(fd, data) COMM_SELECT_READ, (PF) waisReadReply, (caddr_t) data); -#ifdef INSTALL_READ_TIMEOUT_ABOVE_GAP - comm_set_select_handler_plus_timeout(fd, - COMM_SELECT_TIMEOUT, - (PF) waisReadReplyTimeout, - (caddr_t) data, - getReadTimeout()); -#else + /* don't install read handler while we're above the gap */ comm_set_select_handler_plus_timeout(fd, COMM_SELECT_TIMEOUT, (PF) NULL, (caddr_t) NULL, (time_t) 0); -#endif /* dont try reading again for a while */ comm_set_stall(fd, getStallDelay()); return;