kvm: selftests: avoid type punning
authorPaolo Bonzini <pbonzini@redhat.com>
Mon, 20 May 2019 10:02:16 +0000 (12:02 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 24 May 2019 19:27:05 +0000 (21:27 +0200)
commit3b339e2527a6db257fa8f2a4cab3c510432a98d5
tree4c4be2152f9e4a925ccea293f2c4715428d79132
parentbe7fcf1d1701a5266dd36eab4978476f63d1bd57
kvm: selftests: avoid type punning

Avoid warnings from -Wstrict-aliasing by using memcpy.

Reviewed-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
tools/testing/selftests/kvm/lib/ucall.c
tools/testing/selftests/kvm/x86_64/vmx_set_nested_state_test.c