From 38f29ba5372775e8eff318454e64df4774cd1452 Mon Sep 17 00:00:00 2001 From: Michal Novotny Date: Thu, 26 Jul 2018 14:54:00 +0300 Subject: [PATCH] Bug 1475701 - Save Page As doesn't begin MP3 download while tab is open, r=valentin We need to close the cache entry if opening output stream for writing/appending data failed, so the entry isn't blocked for other requests. --- netwerk/protocol/http/nsHttpChannel.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/netwerk/protocol/http/nsHttpChannel.cpp b/netwerk/protocol/http/nsHttpChannel.cpp index b9c70e93a756..3fa3c1155cb6 100644 --- a/netwerk/protocol/http/nsHttpChannel.cpp +++ b/netwerk/protocol/http/nsHttpChannel.cpp @@ -5421,6 +5421,7 @@ nsHttpChannel::InstallCacheListener(int64_t offset) } if (rv == NS_ERROR_FILE_TOO_BIG) { LOG((" entry would exceed max allowed size, not writing it [channel=%p]", this)); + CloseCacheEntry(false); return NS_OK; } if (NS_FAILED(rv)) return rv;