From ca1eb3f1d26f111d12a9c41e0ed075799f63e2a2 Mon Sep 17 00:00:00 2001 From: Michalis Pappas Date: Sat, 29 Mar 2025 09:22:04 +0100 Subject: [PATCH] include/uk/init: Remove const from termination context Remove const from term_ctx to allow libposix-process update the application's exit status during shutdown. Signed-off-by: Michalis Pappas Approved-by: Andrei Tatar Reviewed-by: Andrei Tatar GitHub-Closes: #1633 --- include/uk/init.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/uk/init.h b/include/uk/init.h index 36b4bc153..a44bf8da5 100644 --- a/include/uk/init.h +++ b/include/uk/init.h @@ -64,12 +64,14 @@ struct uk_init_ctx { struct uk_term_ctx { enum ukplat_gstate target; + /* Application exit code */ + int exit_code; /* reserved for future additions */ }; typedef int (*uk_init_func_t)(struct uk_init_ctx *); -typedef void (*uk_term_func_t)(const struct uk_term_ctx *); +typedef void (*uk_term_func_t)(struct uk_term_ctx *); struct uk_inittab_entry { uk_init_func_t init; -- 2.39.5