target/ppc/kvm: Replace variable length array in kvmppc_save_htab()
commitaba594da9645aa6bdb4e2729df2755c186023ca3
authorThomas Huth <thuth@redhat.com>
Wed, 21 Feb 2024 16:26:34 +0000 (21 17:26 +0100)
committerThomas Huth <thuth@redhat.com>
Fri, 23 Feb 2024 07:13:52 +0000 (23 08:13 +0100)
tree756c6208ec8c2edd3e41b5d878e7cf9c0e63ac12
parent0e9a89193d06a3b03b1332c4115d8b822e5ab96c
target/ppc/kvm: Replace variable length array in kvmppc_save_htab()

To be able to compile QEMU with -Wvla (to prevent potential security
issues), we need to get rid of the variable length array in the
kvmppc_save_htab() function. Replace it with a heap allocation instead.

Message-ID: <20240221162636.173136-2-thuth@redhat.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Thomas Huth <thuth@redhat.com>
target/ppc/kvm.c