runtime: fix memory leaks

This commit is contained in:
2026-05-30 19:52:36 +01:00
parent 26b368a512
commit 96bf76aabc
9 changed files with 75 additions and 19 deletions
+5 -5
View File
@@ -31,6 +31,11 @@ static void cmdcall_fini(fx_object *obj, void *priv)
{
struct bshell_cmdcall_p *cmdcall = priv;
if (cmdcall->cmd_target) {
bshell_command_end_processing(cmdcall->cmd_target);
bshell_command_unref(cmdcall->cmd_target);
}
if (cmdcall->cmd_native_path) {
free(cmdcall->cmd_native_path);
}
@@ -44,11 +49,6 @@ static void cmdcall_fini(fx_object *obj, void *priv)
}
fx_vector_destroy(cmdcall->cmd_args, NULL);
if (cmdcall->cmd_target) {
bshell_command_end_processing(cmdcall->cmd_target);
bshell_command_unref(cmdcall->cmd_target);
}
}
static enum bshell_status cmdcall_push_arg(