aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuiz Capitulino <lcapitulino@redhat.com>2011-09-28 16:56:56 -0300
committerLuiz Capitulino <lcapitulino@redhat.com>2011-10-04 11:00:46 -0300
commitd2a80d6bb3fdf319d28f25eb034b32a9f3da7334 (patch)
tree13f6ecba1af8d3e785f7dfcc94535b5cc6decca4
parente1bc2f7b3fb19ab2abcec3d5b15e045b00ae9da1 (diff)
downloadqemu-d2a80d6bb3fdf319d28f25eb034b32a9f3da7334.zip
qemu-d2a80d6bb3fdf319d28f25eb034b32a9f3da7334.tar.gz
qemu-d2a80d6bb3fdf319d28f25eb034b32a9f3da7334.tar.bz2
qapi: Don't use c_var() on enum strings
Otherwise if we have something like 'foo-bar' in the schema, it will be generated as 'foo_bar' in the string lookup table. c_var() is good for C variables, but not for enum strings. Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
-rw-r--r--scripts/qapi-types.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/qapi-types.py b/scripts/qapi-types.py
index 4797a70..3bacc0c 100644
--- a/scripts/qapi-types.py
+++ b/scripts/qapi-types.py
@@ -70,7 +70,7 @@ const char *%(name)s_lookup[] = {
ret += mcgen('''
"%(value)s",
''',
- value=c_var(value).lower())
+ value=value.lower())
ret += mcgen('''
NULL,