From d37e51242ec4eb68473ad6cfad2fc284275c77d7 Mon Sep 17 00:00:00 2001 From: "mscott%netscape.com" Date: Wed, 4 Aug 1999 21:23:26 +0000 Subject: [PATCH] bulletproof some NS_RELEASE's with NS_IF_RELEASE. --- netwerk/base/src/nsAsyncStreamListener.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/netwerk/base/src/nsAsyncStreamListener.cpp b/netwerk/base/src/nsAsyncStreamListener.cpp index 79b4f6b51837..612329f1d373 100644 --- a/netwerk/base/src/nsAsyncStreamListener.cpp +++ b/netwerk/base/src/nsAsyncStreamListener.cpp @@ -128,15 +128,15 @@ nsStreamListenerEvent::nsStreamListenerEvent(nsAsyncStreamObserver* listener, nsIChannel* channel, nsISupports* context) : mListener(listener), mChannel(channel), mContext(context) { - NS_ADDREF(mListener); - NS_ADDREF(mChannel); + NS_IF_ADDREF(mListener); + NS_IF_ADDREF(mChannel); NS_IF_ADDREF(mContext); } nsStreamListenerEvent::~nsStreamListenerEvent() { - NS_RELEASE(mListener); - NS_RELEASE(mChannel); + NS_IF_RELEASE(mListener); + NS_IF_RELEASE(mChannel); NS_IF_RELEASE(mContext); }