unicorn/qemu/target
Peter Maydell b9d5e1d927
target/arm: Free name string in ARMCPRegInfo hashtable entries'
When we add a new entry to the ARMCPRegInfo hash table in
add_cpreg_to_hashtable(), we allocate memory for tehe
ARMCPRegInfo struct itself, and we also g_strdup() the
name string. So the hashtable's value destructor function
must free the name string as well as the struct.

Spotted by clang's leak sanitizer. The leak here is a
small one-off leak at startup, because we don't support
CPU hotplug, and so the only time when we destroy
hash table entries is for the case where ARM_CP_OVERRIDE
means we register a wildcard entry and then override it later.

Backports commit ac87e5072e2cbfcf8e80caac7ef43ceb6914c7af from qemu
2018-12-18 05:09:59 -05:00
..
arm target/arm: Free name string in ARMCPRegInfo hashtable entries' 2018-12-18 05:09:59 -05:00
i386 i386: Add stibp flag name 2018-12-18 03:48:53 -05:00
m68k m68k: Silence compiler warnings 2018-11-16 21:23:55 -05:00
mips target/mips: Disable R5900 support 2018-11-23 18:55:12 -05:00
sparc