Raise meaningful warning when translations.xml has invalid XML.
BUG:FIXED:8969
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
2009-12-09 Serdar Dalgıç <serdar@pardus.org.tr>
|
||||
* pisi/specfile.py: Raise meaningful warning when translations.xml has
|
||||
invalid XML, closes bug #8969
|
||||
|
||||
2009-12-08 Bahadır Kandemir <bahadir@pardus.org.tr>
|
||||
* pisi/atomicoperations.py: Add package name to needs{Restart,Reboot}
|
||||
list if an update requires one of these actions.
|
||||
|
||||
+4
-1
@@ -318,7 +318,10 @@ class SpecFile(xmlfile.XmlFile):
|
||||
def read_translations(self, path):
|
||||
if not os.path.exists(path):
|
||||
return
|
||||
doc = piksemel.parse(path)
|
||||
try:
|
||||
doc = piksemel.parse(path)
|
||||
except Exception, e:
|
||||
raise Error(_("File '%s' has invalid XML") % (path) )
|
||||
|
||||
self._set_i18n(doc.getTag("Source"), self.source)
|
||||
for pak in doc.tags("Package"):
|
||||
|
||||
Reference in New Issue
Block a user