From: Georg Brandl Date: Sat, 10 Jul 2010 11:40:13 +0000 (+0000) Subject: #1434090: properly append child in expatbuilder doctype handler. X-Git-Tag: v3.2a1~244 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=297d97241a065fe2a341fe5f340c81566b762142;p=python #1434090: properly append child in expatbuilder doctype handler. --- diff --git a/Lib/xml/dom/expatbuilder.py b/Lib/xml/dom/expatbuilder.py index a5354b9351..a98fe03235 100644 --- a/Lib/xml/dom/expatbuilder.py +++ b/Lib/xml/dom/expatbuilder.py @@ -242,7 +242,7 @@ class ExpatBuilder: doctype = self.document.implementation.createDocumentType( doctypeName, publicId, systemId) doctype.ownerDocument = self.document - self.document.childNodes.append(doctype) + _append_child(self.document, doctype) self.document.doctype = doctype if self._filter and self._filter.acceptNode(doctype) == FILTER_REJECT: self.document.doctype = None