зеркало из https://github.com/mozilla/pjs.git
Bug 163039, relax sanity check on XML serializer so that we won't throw an error if the serialized document is not XML. This is needed because Bugzilla (at least) abuses XMLSerializer (to edit attachments). r=sicking, sr=jst.
This commit is contained in:
Родитель
5771e037cf
Коммит
2fa45fa451
|
@ -764,7 +764,9 @@ nsXMLContentSerializer::AppendDocumentStart(nsIDOMDocument *aDocument,
|
|||
NS_ENSURE_ARG_POINTER(aDocument);
|
||||
|
||||
nsCOMPtr<nsIXMLDocument> xml(do_QueryInterface(aDocument));
|
||||
NS_ENSURE_TRUE(xml, NS_ERROR_UNEXPECTED);
|
||||
if (!xml) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsAutoString version, encoding, standalone;
|
||||
xml->GetXMLDeclaration(version, encoding, standalone);
|
||||
|
|
Загрузка…
Ссылка в новой задаче