From e305a16510afa74eec20390479e349402e55ef4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= Date: Wed, 13 Jul 2016 02:11:59 +0200 Subject: portio: keep references on portio MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The isa_register_portio_list() function allocates ioports data/state. Let's keep the reference to this data on some owner. This isn't enough to fix leaks, but at least, ASAN stops complaining of direct leaks. Further cleanup would require calling portio_list_del/destroy(). Signed-off-by: Marc-André Lureau Reviewed-by: Paolo Bonzini --- include/hw/ide/internal.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/hw/ide') diff --git a/include/hw/ide/internal.h b/include/hw/ide/internal.h index 7824bc3..a6dd2c3 100644 --- a/include/hw/ide/internal.h +++ b/include/hw/ide/internal.h @@ -480,6 +480,8 @@ struct IDEBus { uint8_t retry_unit; int64_t retry_sector_num; uint32_t retry_nsector; + PortioList portio_list; + PortioList portio2_list; }; #define TYPE_IDE_DEVICE "ide-device" -- cgit v1.1