From 645ac02ee03e54f797c20594755db0f80873ee55 Mon Sep 17 00:00:00 2001 From: Marius Mauch Date: Sun, 28 Sep 2008 18:41:56 +0000 Subject: [PATCH] also accept glsa-2.dtd as valid for GLSAs (patch by Robert Buchholz ) svn path=/main/trunk/; revision=11589 --- pym/portage/glsa.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pym/portage/glsa.py b/pym/portage/glsa.py index 09bc343e6..b7f0c953e 100644 --- a/pym/portage/glsa.py +++ b/pym/portage/glsa.py @@ -432,7 +432,11 @@ class Glsa: self.DOM = xml.dom.minidom.parse(myfile) if not self.DOM.doctype: raise GlsaTypeException(None) - elif self.DOM.doctype.systemId != "http://www.gentoo.org/dtd/glsa.dtd": + elif self.DOM.doctype.systemId == "http://www.gentoo.org/dtd/glsa.dtd": + self.dtdversion = 0 + elif self.DOM.doctype.systemId == "http://www.gentoo.org/dtd/glsa-2.dtd": + self.dtdversion = 2 + else: raise GlsaTypeException(self.DOM.doctype.systemId) myroot = self.DOM.getElementsByTagName("glsa")[0] if self.type == "id" and myroot.getAttribute("id") != self.nr: -- 2.26.2