if (mListeners) { NS_ASSERTION(mListeners->GetSize() == 0, "listeners not removed or notified"); #if 0 PRUint32 size = mListeners->GetSize(); for (PRUint32 i = 0; i < size; i++) { nsIShutdownListener* listener = (nsIShutdownListener*)(*mListeners)[i]; NS_RELEASE(listener); } #endif delete mListeners; }
NotifyListeners(); NS_IF_RELEASE(mObject);
nsServiceEntry::~nsServiceEntry(){    if (mListeners) {        NS_ASSERTION(mListeners->GetSize() == 0, "listeners not removed or notified");#if 0        PRUint32 size = mListeners->GetSize();        for (PRUint32 i = 0; i < size; i++) {            nsIShutdownListener* listener = (nsIShutdownListener*)(*mListeners)[i];            NS_RELEASE(listener);        }#endif        delete mListeners;    }}