From 46dbbfbf2b25821e308080c063671b24424bec99 Mon Sep 17 00:00:00 2001 From: "rpotts%netscape.com" Date: Sat, 19 Feb 2000 00:58:22 +0000 Subject: [PATCH] Partial fix for bug #24711 (r=valeski). If a channel which had been deferred because no socket transports were available resumed and found a valid cache entry it would stall (never finish). A notable example of this was http://www.abcnews.com --- netwerk/protocol/http/src/nsHTTPChannel.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/netwerk/protocol/http/src/nsHTTPChannel.cpp b/netwerk/protocol/http/src/nsHTTPChannel.cpp index 9501701fe3b..76b8afdee6d 100644 --- a/netwerk/protocol/http/src/nsHTTPChannel.cpp +++ b/netwerk/protocol/http/src/nsHTTPChannel.cpp @@ -1135,8 +1135,15 @@ nsHTTPChannel::Open(void) // If the data in the cache is usable, i.e it hasn't expired, then // there's no need to request a socket transport. - if (mCachedContentIsValid) + if (mCachedContentIsValid) { + // The channel is being restarted by the HTTP protocol handler + // and the cache data is usable, so start pumping the data from + // the cache... + if (!mOpenObserver) { + rv = ReadFromCache(0, -1); + } return NS_OK; + } } rv = mHandler->RequestTransport(mURI, this,