trace/simple: Fix compiler warning for 32 bit hosts

gcc complains when a 32 bit pointer is casted to a 64 bit integer.

Cc: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
This commit is contained in:
Stefan Weil 2012-08-13 21:50:56 +02:00 committed by Stefan Hajnoczi
parent db8894f209
commit 964d0a7b2b

View File

@ -79,7 +79,7 @@ def c(events):
)
# pointer var (not string)
elif type_.endswith('*'):
out(' trace_record_write_u64(&rec, (uint64_t)(uint64_t *)%(name)s);',
out(' trace_record_write_u64(&rec, (uintptr_t)(uint64_t *)%(name)s);',
name = name,
)
# primitive data type