提交 59b00542 编写于 作者: E Eric Blake 提交者: Markus Armbruster

qapi: Invoke exception superclass initializer

pylint recommends that every exception class should explicitly
invoke the superclass __init__, even though things seem to work
fine without it.
Signed-off-by: NEric Blake <eblake@redhat.com>
Message-Id: <1443565276-4535-4-git-send-email-eblake@redhat.com>
Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
上级 7408fb67
......@@ -81,6 +81,7 @@ def error_path(parent):
class QAPISchemaError(Exception):
def __init__(self, schema, msg):
Exception.__init__(self)
self.fname = schema.fname
self.msg = msg
self.col = 1
......@@ -98,6 +99,7 @@ class QAPISchemaError(Exception):
class QAPIExprError(Exception):
def __init__(self, expr_info, msg):
Exception.__init__(self)
self.info = expr_info
self.msg = msg
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册