summary refs log tree commit diff stats
path: root/util/vhost-user-server.c
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@linaro.org>2023-11-21 18:40:51 +0100
committerPeter Maydell <peter.maydell@linaro.org>2023-11-27 15:27:46 +0000
commit6e782ffd555808378f69dd606641f0c4b5ca6120 (patch)
tree316fcdc2da7449b54a5a7de0da746632d1829215 /util/vhost-user-server.c
parent4f10c66077e39969940d928077560665e155cac8 (diff)
downloadfocaccia-qemu-6e782ffd555808378f69dd606641f0c4b5ca6120.tar.gz
focaccia-qemu-6e782ffd555808378f69dd606641f0c4b5ca6120.zip
hw/input/stellaris_gamepad: Free StellarisGamepad::keycodes[] array
Commit 0be6bfac62 ("qdev: Implement variable length array properties")
added the DEFINE_PROP_ARRAY() macro with the following comment:

  * It is the responsibility of the device deinit code to free the
  * @_arrayfield memory.

Commit a75f336b97 added:

  DEFINE_PROP_ARRAY("keycodes", StellarisGamepad, num_buttons,
                    keycodes, qdev_prop_uint32, uint32_t),

but forgot to free the 'keycodes' array. Do it in the instance_finalize
handler.

Fixes: a75f336b97 ("hw/input/stellaris_input: Convert to qdev")
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-id: 20231121174051.63038-7-philmd@linaro.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'util/vhost-user-server.c')
0 files changed, 0 insertions, 0 deletions