From 53ea579cb6ac847d1a49b2535f731ff4df415c95 Mon Sep 17 00:00:00 2001 From: "rpotts%netscape.com" Date: Wed, 16 Jun 1999 09:50:30 +0000 Subject: [PATCH] Added an if check around the call out through the event sink... --- netwerk/protocol/http/src/nsHTTPResponseListener.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/netwerk/protocol/http/src/nsHTTPResponseListener.cpp b/netwerk/protocol/http/src/nsHTTPResponseListener.cpp index e13158acd0b7..dc8a952c36b6 100644 --- a/netwerk/protocol/http/src/nsHTTPResponseListener.cpp +++ b/netwerk/protocol/http/src/nsHTTPResponseListener.cpp @@ -281,7 +281,9 @@ nsresult nsHTTPResponseListener::FireOnHeadersAvailable(nsISupports* aContext) // Notify the event sink that response headers are available... nsIHTTPEventSink* pSink= nsnull; m_pConnection->GetEventSink(&pSink); - pSink->OnHeadersAvailable(aContext); + if (pSink) { + pSink->OnHeadersAvailable(aContext); + } // Check for any modules that want to receive headers once they've arrived. NS_WITH_SERVICE(nsINetModuleMgr, pNetModuleMgr, kNetModuleMgrCID, &rv);