[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 23/27] contrib/plugins: fix imatch
From: |
Alex Bennée |
Subject: |
[PATCH v2 23/27] contrib/plugins: fix imatch |
Date: |
Fri, 23 Feb 2024 16:21:58 +0000 |
We can't directly save the ephemeral imatch from argv as that memory
will get recycled.
Message-Id: <20240103173349.398526-40-alex.bennee@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
contrib/plugins/execlog.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/contrib/plugins/execlog.c b/contrib/plugins/execlog.c
index 82dc2f584e2..f262e5555eb 100644
--- a/contrib/plugins/execlog.c
+++ b/contrib/plugins/execlog.c
@@ -199,7 +199,7 @@ static void parse_insn_match(char *match)
if (!imatches) {
imatches = g_ptr_array_new();
}
- g_ptr_array_add(imatches, match);
+ g_ptr_array_add(imatches, g_strdup(match));
}
static void parse_vaddr_match(char *match)
--
2.39.2
- [PATCH v2 17/27] cpu: call plugin init hook asynchronously, (continued)
- [PATCH v2 17/27] cpu: call plugin init hook asynchronously, Alex Bennée, 2024/02/23
- [PATCH v2 03/27] target/arm: Use GDBFeature for dynamic XML, Alex Bennée, 2024/02/23
- [PATCH v2 05/27] target/riscv: Use GDBFeature for dynamic XML, Alex Bennée, 2024/02/23
- [PATCH v2 27/27] docs/devel: plugins can trigger a tb flush, Alex Bennée, 2024/02/23
- [PATCH v2 04/27] target/ppc: Use GDBFeature for dynamic XML, Alex Bennée, 2024/02/23
- [PATCH v2 06/27] gdbstub: Use GDBFeature for gdb_register_coprocessor, Alex Bennée, 2024/02/23
- [PATCH v2 14/27] plugins: add qemu_plugin_num_vcpus function, Alex Bennée, 2024/02/23
- [PATCH v2 22/27] tests/tcg: expand insn test case to exercise register API, Alex Bennée, 2024/02/23
- [PATCH v2 19/27] gdbstub: expose api to find registers, Alex Bennée, 2024/02/23
- [PATCH v2 25/27] docs/devel: lift example and plugin API sections up, Alex Bennée, 2024/02/23
- [PATCH v2 23/27] contrib/plugins: fix imatch,
Alex Bennée <=
- [PATCH v2 01/27] tests/tcg: update licenses to GPLv2 as intended, Alex Bennée, 2024/02/23
- [PATCH v2 10/27] gdbstub: Infer number of core registers from XML, Alex Bennée, 2024/02/23
- [PATCH v2 09/27] gdbstub: Simplify XML lookup, Alex Bennée, 2024/02/23
- [PATCH v2 16/27] linux-user: ensure nios2 processes queued work, Alex Bennée, 2024/02/23
- [PATCH v2 18/27] plugins: Use different helpers when reading registers, Alex Bennée, 2024/02/23
- [PATCH v2 20/27] plugins: create CPUPluginState and migrate plugin_mask, Alex Bennée, 2024/02/23
- [PATCH v2 24/27] contrib/plugins: extend execlog to track register changes, Alex Bennée, 2024/02/23
- [PATCH v2 26/27] docs/devel: document some plugin assumptions, Alex Bennée, 2024/02/23