提交 bb1ff5e7 编写于 作者: D Daniel P. Berrange

Fixed string concatenation in case where there is no lower level error

上级 28a60cbc
......@@ -63,7 +63,10 @@ class libvirtError(Exception):
return self.err[8]
def __str__(self):
return Exception.__str__(self) + " " + self.get_error_message()
if self.get_error_message() is None:
return Exception.__str__(self)
else:
return Exception.__str__(self) + " " + self.get_error_message()
#
# register the libvirt global error handler
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册