Bug 1329506 - Add missing non-null check in mozilla::net::DoUpdateExpirationTime. r=michal a=jcristau
authorHonza Bambas <honzab.moz@firemni.cz>
Tue, 17 Jan 2017 07:36:00 -0500
changeset 366775 56b35490bf160226dd5c48ad9f600183f92a4cdf
parent 366774 bbc148936ba4da23034c02eff006f7e33c862974
child 366776 1ba06428e641e5ee399a329920b2ef54074264bc
push id6846
push usercbook@mozilla.com
push dateTue, 31 Jan 2017 15:39:52 +0000
treeherdermozilla-beta@f01c5c342a5c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmichal, jcristau
bugs1329506
milestone52.0
Bug 1329506 - Add missing non-null check in mozilla::net::DoUpdateExpirationTime. r=michal a=jcristau
netwerk/cache2/CacheEntry.cpp
--- a/netwerk/cache2/CacheEntry.cpp
+++ b/netwerk/cache2/CacheEntry.cpp
@@ -1478,17 +1478,17 @@ NS_IMETHODIMP CacheEntry::Recreate(bool 
 
   RefPtr<CacheEntryHandle> handle = ReopenTruncated(aMemoryOnly, nullptr);
   if (handle) {
     handle.forget(_retval);
     return NS_OK;
   }
 
   BackgroundOp(Ops::CALLBACKS, true);
-  return NS_OK;
+  return NS_ERROR_NOT_AVAILABLE;
 }
 
 NS_IMETHODIMP CacheEntry::GetDataSize(int64_t *aDataSize)
 {
   LOG(("CacheEntry::GetDataSize [this=%p]", this));
   *aDataSize = 0;
 
   {