summaryrefslogtreecommitdiff
path: root/pysnmp
diff options
context:
space:
mode:
authorelie <elie>2015-06-03 18:31:29 +0000
committerelie <elie>2015-06-03 18:31:29 +0000
commit49cef7f6d3234dd38ecfe1fe63fa31ddeaf56d2c (patch)
tree1ebd452fc43621cdc8430c3ec0546c9c38ccc6a6 /pysnmp
parentc95166ec970e863b604a1f96aa2f3e7b04ce1f34 (diff)
downloadpysnmp-git-49cef7f6d3234dd38ecfe1fe63fa31ddeaf56d2c.tar.gz
fix to pysmi status interpretation
Diffstat (limited to 'pysnmp')
-rw-r--r--pysnmp/smi/builder.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pysnmp/smi/builder.py b/pysnmp/smi/builder.py
index 4c0ce9c2..22c77764 100644
--- a/pysnmp/smi/builder.py
+++ b/pysnmp/smi/builder.py
@@ -321,7 +321,7 @@ class MibBuilder:
if self.__mibCompiler:
debug.logger & debug.flagBld and debug.logger('loadModules: calling MIB compiler for %s' % modName)
status = self.__mibCompiler.compile(modName)
- errs = '; '.join([str(x.error) for x in status.values() if x in ('failed', 'missing')])
+ errs = '; '.join([hasattr(x, 'error') and str(x.error) or x for x in status.values() if x in ('failed', 'missing')])
if errs:
raise error.MibNotFoundError('%s compilation error(s): %s' % (modName, errs))
# compilation suceeded, MIB might load now