diff --git a/scripts/qapi.py b/scripts/qapi.py index 0265b404dd21bb168d638ca635d1e54978f93953..86e96089af6a42bfa3fbaa48e496c6dc8af37721 100644 --- a/scripts/qapi.py +++ b/scripts/qapi.py @@ -116,7 +116,7 @@ class QAPISchema: continue try: fobj = open(include_path, 'r') - except IOError as e: + except IOError, e: raise QAPIExprError(expr_info, '%s: %s' % (e.strerror, include)) exprs_include = QAPISchema(fobj, include, self.include_hist,