aboutsummaryrefslogtreecommitdiff
path: root/scripts/tracetool/__init__.py
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2018-02-19 16:44:12 +0000
committerPeter Maydell <peter.maydell@linaro.org>2018-02-19 16:44:12 +0000
commitafd3397a8149d8b645004e459bf2002d78f5e267 (patch)
tree5e957f9f3793ab5c3ab68e5da7044030aef730fc /scripts/tracetool/__init__.py
parent299a2e6fac397be9b82c66583d53d1daaa3ffe6c (diff)
parent7f1d87ab0fd94cef5086e2879716958303281054 (diff)
Merge remote-tracking branch 'remotes/stefanha/tags/tracing-pull-request' into staging
# gpg: Signature made Mon 19 Feb 2018 16:19:46 GMT # gpg: using RSA key 9CA4ABB381AB73C8 # gpg: Good signature from "Stefan Hajnoczi <stefanha@redhat.com>" # gpg: aka "Stefan Hajnoczi <stefanha@gmail.com>" # Primary key fingerprint: 8695 A8BF D3F9 7CDA AC35 775A 9CA4 ABB3 81AB 73C8 * remotes/stefanha/tags/tracing-pull-request: trace: avoid SystemTap "char const" warnings tracetool: For ust trace bool type as ctf_integer tracetool: Update argument format regex to non-greedy star Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'scripts/tracetool/__init__.py')
-rw-r--r--scripts/tracetool/__init__.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/tracetool/__init__.py b/scripts/tracetool/__init__.py
index 1a9733da9a..3646c2b9fc 100644
--- a/scripts/tracetool/__init__.py
+++ b/scripts/tracetool/__init__.py
@@ -261,8 +261,9 @@ class Event(object):
self.name,
self.args,
fmt)
-
- _FMT = re.compile("(%[\d\.]*\w+|%.*PRI\S+)")
+ # Star matching on PRI is dangerous as one might have multiple
+ # arguments with that format, hence the non-greedy version of it.
+ _FMT = re.compile("(%[\d\.]*\w+|%.*?PRI\S+)")
def formats(self):
"""List conversion specifiers in the argument print format string."""