diff --git a/netwerk/protocol/about/src/nsAboutCache.cpp b/netwerk/protocol/about/src/nsAboutCache.cpp index 12795afd2da..a1ff2ced20a 100644 --- a/netwerk/protocol/about/src/nsAboutCache.cpp +++ b/netwerk/protocol/about/src/nsAboutCache.cpp @@ -152,6 +152,10 @@ nsAboutCache::VisitDevice(const char *deviceID, if (mDeviceID.IsEmpty() || mDeviceID.Equals(deviceID)) { + // We need mStream for this + if (!mStream) + return NS_ERROR_FAILURE; + // Write out the Cache Name deviceInfo->GetDescription(getter_Copies(str)); @@ -206,6 +210,10 @@ nsAboutCache::VisitEntry(const char *deviceID, nsICacheEntryInfo *entryInfo, PRBool *visitNext) { + // We need mStream for this + if (!mStream) + return NS_ERROR_FAILURE; + nsresult rv; PRUint32 bytesWritten; nsCAutoString key;