Deny GetService() requests which cause Creation of new objects on

shutdown. r=jband, r=ScottPutterman
This commit is contained in:
dp%netscape.com 1999-11-03 05:38:45 +00:00
Родитель 54d23dfc44
Коммит 5bc4da0375
1 изменённых файлов: 7 добавлений и 0 удалений

Просмотреть файл

@ -232,6 +232,13 @@ nsServiceManagerImpl::GetService(const nsCID& aClass, const nsIID& aIID,
}
}
}
else if (mShuttingDown) {
// When processing shutdown, dont process new GetService() requests
#ifdef DEBUG_dp
NS_WARN_IF_FALSE(PR_FALSE, "Creating new service on shutdown. Denied.");
#endif /* DEBUG_dp */
rv = NS_ERROR_UNEXPECTED;
}
else {
nsISupports* service;
// We need to not be holding the service manager's monitor while calling