summaryrefslogtreecommitdiffstats
path: root/scripts/qapi
diff options
context:
space:
mode:
authorMarkus Armbruster2020-03-20 10:18:04 +0100
committerMarkus Armbruster2020-09-07 16:35:16 +0200
commitd98884b75df3676f94d93fbaf6372ca705dc2aee (patch)
tree3e48c319caecf6908c92f5ed11458a53b44f932b /scripts/qapi
parentMerge remote-tracking branch 'remotes/kraxel/tags/vga-20200904-pull-request' ... (diff)
downloadqemu-d98884b75df3676f94d93fbaf6372ca705dc2aee.tar.gz
qemu-d98884b75df3676f94d93fbaf6372ca705dc2aee.tar.xz
qemu-d98884b75df3676f94d93fbaf6372ca705dc2aee.zip
qapi: Reject section markup in definition documentation
Section markup in definition documentation makes no sense and can produce invalid Texinfo. Reject. Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20200320091805.5585-2-armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'scripts/qapi')
-rw-r--r--scripts/qapi/parser.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/qapi/parser.py b/scripts/qapi/parser.py
index abadacbb0e..f12c67d7d2 100644
--- a/scripts/qapi/parser.py
+++ b/scripts/qapi/parser.py
@@ -282,6 +282,11 @@ class QAPISchemaParser:
doc.end_comment()
self.accept()
return doc
+ if self.val.startswith('# ='):
+ if doc.symbol:
+ raise QAPIParseError(
+ self,
+ "unexpected '=' markup in definition documentation")
doc.append(self.val)
self.accept(False)