commit fd75c9f0313d8878674307014aba5fc1732ac33c
Author: Elan Ruusamäe <[email protected]>
Date: Mon Dec 14 23:20:18 2015 +0200
handle macro retrieve error
pldnotify.py | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/pldnotify.py b/pldnotify.py
index 527f1ee..1fab5c8 100755
--- a/pldnotify.py
+++ b/pldnotify.py
@@ -62,8 +62,11 @@ class Checker:
except rpm.error, e:
raise ValueError, "%s: %s" % (specfile, e.message)
- self.name = macros['name']
- self.version = macros['version']
+ try:
+ self.name = macros['name']
+ self.version = macros['version']
+ except Exception, e:
+ raise ValueError, "%s: macro error: %s" % (specfile, e.message)
name = path.splitext(path.basename(specfile))[0]
if self.name != name:
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/pldnotify.git/commitdiff/fd75c9f0313d8878674307014aba5fc1732ac33c
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit