Bug 1140065 Check for null actor before using it in CacheStorageChild::RecvOpenResponse(). r=ehsan
authorBen Kelly <ben@wanderview.com>
Thu, 05 Mar 2015 16:31:21 -0800
changeset 232130 48fb33eac947db0299c5588bc5db0649fb7d6984
parent 232129 1e3ba87c78002755caafa273a0cd19dd24652d44
child 232131 ca2ba62ff1df1358d201480eb0c22688a4d1f6bf
push id56459
push userbkelly@mozilla.com
push dateFri, 06 Mar 2015 00:31:11 +0000
treeherdermozilla-inbound@48fb33eac947 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersehsan
bugs1140065
milestone39.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1140065 Check for null actor before using it in CacheStorageChild::RecvOpenResponse(). r=ehsan
dom/cache/CacheStorageChild.cpp
--- a/dom/cache/CacheStorageChild.cpp
+++ b/dom/cache/CacheStorageChild.cpp
@@ -132,17 +132,19 @@ CacheStorageChild::RecvOpenResponse(cons
   }
 
   CacheChild* cacheChild = static_cast<CacheChild*>(aActor);
 
   // Since FeatureNotified() returned false above, we are guaranteed that
   // the feature won't try to shutdown the actor until after we create the
   // Cache DOM object in the listener's RecvOpenResponse() method.  This
   // is important because StartShutdown() expects a Cache object listener.
-  cacheChild->SetFeature(GetFeature());
+  if (cacheChild) {
+    cacheChild->SetFeature(GetFeature());
+  }
 
   listener->RecvOpenResponse(aRequestId, aRv, cacheChild);
   return true;
 }
 
 bool
 CacheStorageChild::RecvDeleteResponse(const RequestId& aRequestId,
                                       const nsresult& aRv,