summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/qapi-types.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/scripts/qapi-types.py b/scripts/qapi-types.py
index fd42d71da1..ddcfed9f4b 100644
--- a/scripts/qapi-types.py
+++ b/scripts/qapi-types.py
@@ -22,7 +22,10 @@ def generate_fwd_struct(name, members, builtin_type=False):
typedef struct %(name)sList
{
- %(type)s value;
+ union {
+ %(type)s value;
+ uint64_t padding;
+ };
struct %(name)sList *next;
} %(name)sList;
''',
@@ -35,7 +38,10 @@ typedef struct %(name)s %(name)s;
typedef struct %(name)sList
{
- %(name)s *value;
+ union {
+ %(name)s *value;
+ uint64_t padding;
+ };
struct %(name)sList *next;
} %(name)sList;
''',