From 297d97241a065fe2a341fe5f340c81566b762142 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Sat, 10 Jul 2010 11:40:13 +0000 Subject: [PATCH] #1434090: properly append child in expatbuilder doctype handler. --- Lib/xml/dom/expatbuilder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 -- 2.40.0