mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-28 13:21:28 +00:00
Fix double-delete on error return. Bug 188729 stuff, r=sicking, sr=peterv, a=dbaron
This commit is contained in:
parent
60c73ca747
commit
78eed0300d
@ -199,10 +199,8 @@ NS_NewXMLContentSink(nsIXMLContentSink** aResult,
|
||||
|
||||
nsCOMPtr<nsIXMLContentSink> kungFuDeathGrip = it;
|
||||
nsresult rv = it->Init(aDoc, aURL, aWebShell, aChannel);
|
||||
if (NS_OK != rv) {
|
||||
delete it;
|
||||
return rv;
|
||||
}
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
return CallQueryInterface(it, aResult);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user