Commit 24f4d3d3 authored by Stefan Hajnoczi's avatar Stefan Hajnoczi

tracetool: report error on foo() instead of foo(void)

C functions with no arguments must be declared foo(void) instead of
foo().  The tracetool argument list parser has never accepted an empty
argument list.  This patch adds a clear error message for this error
Signed-off-by: 's avatarStefan Hajnoczi <>
Reviewed-by: 's avatarEric Blake <>
Signed-off-by: 's avatarStefan Hajnoczi <>
parent 6e497fa1
......@@ -75,6 +75,8 @@ class Arguments:
res = []
for arg in arg_str.split(","):
arg = arg.strip()
if not arg:
raise ValueError("Empty argument (did you forget to use 'void'?)")
if arg == 'void':
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment