qemu/gdbstub
Alex Bennée e8122a7118 gdbstub: Re-factor gdb command extensions
Coverity reported a memory leak (CID 1549757) in this code and its
admittedly rather clumsy handling of extending the command table.
Instead of handing over a full array of the commands lets use the
lighter weight GPtrArray and simply test for the presence of each
entry as we go. This avoids complications of transferring ownership of
arrays and keeps the final command entries as static entries in the
target code.

Cc: Akihiko Odaki <akihiko.odaki@daynix.com>
Cc: Gustavo Bueno Romero <gustavo.romero@linaro.org>
Cc: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Gustavo Romero <gustavo.romero@linaro.org>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20240718094523.1198645-4-alex.bennee@linaro.org>
2024-07-22 09:37:44 +01:00
..
gdbstub.c gdbstub: Re-factor gdb command extensions 2024-07-22 09:37:44 +01:00
internals.h gdbstub: Make hex conversion function non-internal 2024-07-05 12:35:19 +01:00
meson.build meson: Drop the .fa library suffix 2024-07-03 18:41:26 +02:00
syscalls.c gdbstub: Move GdbCmdParseEntry into a new header file 2024-07-05 12:35:01 +01:00
system.c gdbstub: Move GdbCmdParseEntry into a new header file 2024-07-05 12:35:01 +01:00
trace-events gdbstub: Rename 'softmmu' -> 'system' 2023-10-07 19:02:59 +02:00
trace.h gdbstub: move into its own sub directory 2022-10-06 11:53:41 +01:00
user-target.c gdbstub: Move GdbCmdParseEntry into a new header file 2024-07-05 12:35:01 +01:00
user.c gdbstub: Move GdbCmdParseEntry into a new header file 2024-07-05 12:35:01 +01:00