mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 702275 - check AddObserver return code in nsDOMStorage.cpp. r=honzab.
This commit is contained in:
parent
1b8e035e99
commit
74f049f0da
@ -287,16 +287,27 @@ nsDOMStorageManager::Initialize()
|
||||
if (!os)
|
||||
return NS_OK;
|
||||
|
||||
os->AddObserver(gStorageManager, "cookie-changed", false);
|
||||
os->AddObserver(gStorageManager, "offline-app-removed", false);
|
||||
os->AddObserver(gStorageManager, NS_PRIVATE_BROWSING_SWITCH_TOPIC, false);
|
||||
os->AddObserver(gStorageManager, "profile-after-change", false);
|
||||
os->AddObserver(gStorageManager, "perm-changed", false);
|
||||
os->AddObserver(gStorageManager, "browser:purge-domain-data", false);
|
||||
nsresult rv;
|
||||
rv = os->AddObserver(gStorageManager, "cookie-changed", false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, "offline-app-removed", false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, NS_PRIVATE_BROWSING_SWITCH_TOPIC,
|
||||
false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, "profile-after-change", false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, "perm-changed", false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, "browser:purge-domain-data", false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
// Used for temporary table flushing
|
||||
os->AddObserver(gStorageManager, "profile-before-change", false);
|
||||
os->AddObserver(gStorageManager, NS_XPCOM_SHUTDOWN_OBSERVER_ID, false);
|
||||
os->AddObserver(gStorageManager, NS_DOMSTORAGE_FLUSH_TIMER_TOPIC, false);
|
||||
rv = os->AddObserver(gStorageManager, "profile-before-change", false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, NS_XPCOM_SHUTDOWN_OBSERVER_ID, false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
rv = os->AddObserver(gStorageManager, NS_DOMSTORAGE_FLUSH_TIMER_TOPIC, false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user