From: wessels <> Date: Tue, 12 Jan 1999 03:16:04 +0000 (+0000) Subject: send old entry if IMS request results in 500's status X-Git-Tag: SQUID_3_0_PRE1~2438 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a05cea5b0533874049eecf7f33af469c7ddd743a;p=thirdparty%2Fsquid.git send old entry if IMS request results in 500's status --- diff --git a/src/client_side.cc b/src/client_side.cc index 05287f58a7..f79f9ee6b3 100644 --- a/src/client_side.cc +++ b/src/client_side.cc @@ -1,6 +1,6 @@ /* - * $Id: client_side.cc,v 1.427 1999/01/11 16:50:29 wessels Exp $ + * $Id: client_side.cc,v 1.428 1999/01/11 20:16:04 wessels Exp $ * * DEBUG: section 33 Client-side Routines * AUTHOR: Duane Wessels @@ -334,6 +334,12 @@ clientGetsOldEntry(StoreEntry * new_entry, StoreEntry * old_entry, request_t * r debug(33, 5) ("clientGetsOldEntry: YES, broken HTTP reply\n"); return 1; } + /* If the reply is a failure then send the old object as a last + * resort */ + if (status >= 500 && status < 600) { + debug(33, 2) ("clientGetsOldEntry: YES, failure reply=%d\n", status); + return 1; + } /* If the reply is anything but "Not Modified" then * we must forward it to the client */ if (HTTP_NOT_MODIFIED != status) {