diff options
author | Markus Armbruster <armbru@redhat.com> | 2013-07-27 17:41:57 +0200 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2013-07-29 10:37:11 -0500 |
commit | 9213aa5391f7c8d3766420d96888f1353af4c890 (patch) | |
tree | 93d0bfe561e2e71efbf8388b0ebc3ffb3732117d /scripts/qapi.py | |
parent | 2caba36cc61ee3993334bc423f0852f8006fdfcf (diff) |
qapi.py: Reject invalid characters in schema file
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-id: 1374939721-7876-6-git-send-email-armbru@redhat.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'scripts/qapi.py')
-rw-r--r-- | scripts/qapi.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/scripts/qapi.py b/scripts/qapi.py index 342d16c4e8..0b48a1e50a 100644 --- a/scripts/qapi.py +++ b/scripts/qapi.py @@ -101,6 +101,8 @@ class QAPISchema: if self.cursor == len(self.src): self.tok = None return + elif not self.tok.isspace(): + raise QAPISchemaError(self, 'Stray "%s"' % self.tok) def get_members(self): expr = OrderedDict() |