Bug 1040086 - EV identifier missing when restoring session with HTTP cache v2. r=michal, a=lmandel
authorHonza Bambas <honzab.moz@firemni.cz>
Thu, 21 Aug 2014 15:50:16 -0700
changeset 208374 33ea2d7e342e
parent 208373 8f49d60bf5c9
child 208375 2f61f6e44a33
push id3848
push userryanvm@gmail.com
push date2014-08-22 02:08 +0000
treeherdermozilla-beta@58eb677e55f3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmichal, lmandel
bugs1040086
milestone32.0
Bug 1040086 - EV identifier missing when restoring session with HTTP cache v2. r=michal, a=lmandel
netwerk/protocol/http/nsHttpChannel.cpp
--- a/netwerk/protocol/http/nsHttpChannel.cpp
+++ b/netwerk/protocol/http/nsHttpChannel.cpp
@@ -3645,16 +3645,21 @@ nsHttpChannel::CloseCacheEntry(bool doom
             doom = true;
     }
     else if (mCacheEntryIsWriteOnly)
         doom = true;
 
     if (doom) {
         LOG(("  dooming cache entry!!"));
         mCacheEntry->AsyncDoom(nullptr);
+    } else {
+      // Store updated security info, makes cached EV status race less likely
+      // (see bug 1040086)
+      if (mSecurityInfo)
+          mCacheEntry->SetSecurityInfo(mSecurityInfo);
     }
 
     mCachedResponseHead = nullptr;
 
     mCachePump = nullptr;
     mCacheEntry = nullptr;
     mCacheEntryIsWriteOnly = false;
     mInitedCacheEntry = false;