updating for the new net notification service.

changed Qi


git-svn-id: svn://10.0.0.236/trunk@43490 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
dougt%netscape.com 1999-08-18 09:35:04 +00:00
parent 816c2914d7
commit 8b121b25d9
2 changed files with 7 additions and 8 deletions

View File

@ -28,7 +28,7 @@
///////////////////////////////////
// nsISupports
NS_IMPL_ISUPPORTS(nsCookieHTTPNotify, nsIHTTPNotify::GetIID());
NS_IMPL_ISUPPORTS2(nsCookieHTTPNotify, nsIHTTPNotify, nsINetNotify);
///////////////////////////////////
// nsCookieHTTPNotify Implementation

View File

@ -120,26 +120,25 @@ nsresult nsCookieService::Init() {
if (NS_FAILED(rv)) {
return rv;
}
nsIEventQueue* eventQ;
NS_WITH_SERVICE(nsIEventQueueService, eventQService, kEventQueueServiceCID, &rv);
if (NS_SUCCEEDED(rv)) {
if (NS_SUCCEEDED(rv))
{
rv = eventQService->CreateThreadEventQueue();
if (NS_FAILED(rv)) {
return rv;
}
rv = eventQService->GetThreadEventQueue(PR_CurrentThread(), &eventQ);
}
if (NS_FAILED(rv)) {
if (NS_FAILED(rv))
return rv;
}
if (NS_FAILED(rv = NS_NewCookieHTTPNotify(&mCookieHTTPNotify))) {
return rv;
}
rv = pNetModuleMgr->RegisterModule(NS_NETWORK_MODULE_MANAGER_HTTP_REQUEST_PROGID, eventQ, mCookieHTTPNotify, &kCookieHTTPNotifyCID);
rv = pNetModuleMgr->RegisterModule(NS_NETWORK_MODULE_MANAGER_HTTP_REQUEST_PROGID, mCookieHTTPNotify);
if (NS_FAILED(rv)) {
return rv;
}
rv = pNetModuleMgr->RegisterModule(NS_NETWORK_MODULE_MANAGER_HTTP_RESPONSE_PROGID, eventQ, mCookieHTTPNotify, &kCookieHTTPNotifyCID);
rv = pNetModuleMgr->RegisterModule(NS_NETWORK_MODULE_MANAGER_HTTP_RESPONSE_PROGID, mCookieHTTPNotify);
if (NS_FAILED(rv)) {
return rv;
}