зеркало из https://github.com/mozilla/gecko-dev.git
bulletproof some NS_RELEASE's with NS_IF_RELEASE.
This commit is contained in:
Родитель
667daab831
Коммит
d37e51242e
|
@ -128,15 +128,15 @@ nsStreamListenerEvent::nsStreamListenerEvent(nsAsyncStreamObserver* listener,
|
||||||
nsIChannel* channel, nsISupports* context)
|
nsIChannel* channel, nsISupports* context)
|
||||||
: mListener(listener), mChannel(channel), mContext(context)
|
: mListener(listener), mChannel(channel), mContext(context)
|
||||||
{
|
{
|
||||||
NS_ADDREF(mListener);
|
NS_IF_ADDREF(mListener);
|
||||||
NS_ADDREF(mChannel);
|
NS_IF_ADDREF(mChannel);
|
||||||
NS_IF_ADDREF(mContext);
|
NS_IF_ADDREF(mContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
nsStreamListenerEvent::~nsStreamListenerEvent()
|
nsStreamListenerEvent::~nsStreamListenerEvent()
|
||||||
{
|
{
|
||||||
NS_RELEASE(mListener);
|
NS_IF_RELEASE(mListener);
|
||||||
NS_RELEASE(mChannel);
|
NS_IF_RELEASE(mChannel);
|
||||||
NS_IF_RELEASE(mContext);
|
NS_IF_RELEASE(mContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче