diff --git a/netwerk/protocol/http/Http2Session.cpp b/netwerk/protocol/http/Http2Session.cpp index 7183e4216a50..b0617b7e8ee2 100644 --- a/netwerk/protocol/http/Http2Session.cpp +++ b/netwerk/protocol/http/Http2Session.cpp @@ -896,7 +896,10 @@ Http2Session::CleanupStream(Http2Stream *aStream, nsresult aResult, { MOZ_ASSERT(PR_GetCurrentThread() == gSocketThread); LOG3(("Http2Session::CleanupStream %p %p 0x%X %X\n", - this, aStream, aStream->StreamID(), aResult)); + this, aStream, aStream ? aStream->StreamID() : 0, aResult)); + if (!aStream) { + return; + } Http2PushedStream *pushSource = nullptr; diff --git a/netwerk/protocol/http/SpdySession3.cpp b/netwerk/protocol/http/SpdySession3.cpp index 291e229c992b..ebcab0fe08ce 100644 --- a/netwerk/protocol/http/SpdySession3.cpp +++ b/netwerk/protocol/http/SpdySession3.cpp @@ -837,7 +837,10 @@ SpdySession3::CleanupStream(SpdyStream3 *aStream, nsresult aResult, { MOZ_ASSERT(PR_GetCurrentThread() == gSocketThread); LOG3(("SpdySession3::CleanupStream %p %p 0x%X %X\n", - this, aStream, aStream->StreamID(), aResult)); + this, aStream, aStream ? aStream->StreamID() : 0, aResult)); + if (!aStream) { + return; + } SpdyPushedStream3 *pushSource = nullptr; diff --git a/netwerk/protocol/http/SpdySession31.cpp b/netwerk/protocol/http/SpdySession31.cpp index 9240d8c1d3e0..0943145e2d25 100644 --- a/netwerk/protocol/http/SpdySession31.cpp +++ b/netwerk/protocol/http/SpdySession31.cpp @@ -874,7 +874,10 @@ SpdySession31::CleanupStream(SpdyStream31 *aStream, nsresult aResult, { MOZ_ASSERT(PR_GetCurrentThread() == gSocketThread); LOG3(("SpdySession31::CleanupStream %p %p 0x%X %X\n", - this, aStream, aStream->StreamID(), aResult)); + this, aStream, aStream ? aStream->StreamID() : 0, aResult)); + if (!aStream) { + return; + } SpdyPushedStream31 *pushSource = nullptr;