зеркало из https://github.com/mozilla/gecko-dev.git
Fix crasher when loading XUL in viewer and no localstore is present.
This commit is contained in:
Родитель
ffaae7a7ee
Коммит
de8f3449d5
|
@ -3757,13 +3757,16 @@ XULDocumentImpl::Init(void)
|
|||
rv = nsServiceManager::GetService(kLocalStoreCID,
|
||||
NS_GET_IID(nsIRDFDataSource),
|
||||
(nsISupports**) &localstore);
|
||||
mLocalStore = localstore;
|
||||
NS_IF_RELEASE(localstore);
|
||||
|
||||
// this _could_ fail; e.g., if we've tried to grab the local store
|
||||
// before profiles have initialized. If so, no big deal; nothing
|
||||
// will persist.
|
||||
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
mLocalStore = localstore;
|
||||
NS_IF_RELEASE(localstore);
|
||||
}
|
||||
|
||||
#if 0
|
||||
// construct a selection object
|
||||
if (NS_FAILED(rv = nsComponentManager::CreateInstance(kRangeListCID,
|
||||
|
|
|
@ -3757,13 +3757,16 @@ XULDocumentImpl::Init(void)
|
|||
rv = nsServiceManager::GetService(kLocalStoreCID,
|
||||
NS_GET_IID(nsIRDFDataSource),
|
||||
(nsISupports**) &localstore);
|
||||
mLocalStore = localstore;
|
||||
NS_IF_RELEASE(localstore);
|
||||
|
||||
// this _could_ fail; e.g., if we've tried to grab the local store
|
||||
// before profiles have initialized. If so, no big deal; nothing
|
||||
// will persist.
|
||||
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
mLocalStore = localstore;
|
||||
NS_IF_RELEASE(localstore);
|
||||
}
|
||||
|
||||
#if 0
|
||||
// construct a selection object
|
||||
if (NS_FAILED(rv = nsComponentManager::CreateInstance(kRangeListCID,
|
||||
|
|
Загрузка…
Ссылка в новой задаче