summary refs log tree commit diff stats
path: root/scripts/update-linux-headers.sh
diff options
context:
space:
mode:
authorShannon Zhao <zhaoshenglong@huawei.com>2018-05-31 14:50:53 +0100
committerPeter Maydell <peter.maydell@linaro.org>2018-05-31 16:32:35 +0100
commit6e3e723966197463117642d8a5fd7b4f6446e510 (patch)
tree3fbefd8ee42e9271f2c2e0ccc1b3183c7bb5e5d1 /scripts/update-linux-headers.sh
parente0a37e266084fb26951465e08515af46807c312c (diff)
downloadfocaccia-qemu-6e3e723966197463117642d8a5fd7b4f6446e510.tar.gz
focaccia-qemu-6e3e723966197463117642d8a5fd7b4f6446e510.zip
ARM: ACPI: Fix use-after-free due to memory realloc
acpi_data_push uses g_array_set_size to resize the memory size. If there
is no enough contiguous memory, the address will be changed. So previous
pointer could not be used any more. It must update the pointer and use
the new one.

Also, previous codes wrongly use le32 conversion of iort->node_offset
for subsequent computations that will result incorrect value if host is
not litlle endian. So use the non-converted one instead.

Signed-off-by: Shannon Zhao <zhaoshenglong@huawei.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Message-id: 1527663951-14552-1-git-send-email-zhaoshenglong@huawei.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'scripts/update-linux-headers.sh')
0 files changed, 0 insertions, 0 deletions