зеркало из https://github.com/mozilla/pjs.git
Bug 155192 crash [@nsRDFResource::~nsRDFResource] if gRDFService wasn't created
patch by tingley@sundell.net r=timeless sr=bz
This commit is contained in:
Родитель
642e1817f6
Коммит
177bb07bf4
|
@ -68,15 +68,17 @@ nsRDFResource::~nsRDFResource(void)
|
|||
delete doomed;
|
||||
}
|
||||
|
||||
gRDFService->UnregisterResource(this);
|
||||
if (mURI) {
|
||||
gRDFService->UnregisterResource(this);
|
||||
|
||||
// N.B. that we need to free the URI *after* we un-cache the resource,
|
||||
// due to the way that the resource manager is implemented.
|
||||
nsCRT::free(mURI);
|
||||
// N.B. that we need to free the URI *after* we un-cache the resource,
|
||||
// due to the way that the resource manager is implemented.
|
||||
nsCRT::free(mURI);
|
||||
|
||||
if (--gRDFServiceRefCnt == 0) {
|
||||
nsServiceManager::ReleaseService(kRDFServiceCID, gRDFService);
|
||||
gRDFService = nsnull;
|
||||
if (--gRDFServiceRefCnt == 0) {
|
||||
nsServiceManager::ReleaseService(kRDFServiceCID, gRDFService);
|
||||
gRDFService = nsnull;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче