mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-12-25 22:43:50 +01:00
core/init: allow to run callback on main exit
This commit is contained in:
parent
c6ac50f2e8
commit
ea799e738d
@ -60,7 +60,12 @@ static void *main_trampoline(void *arg)
|
||||
LOG_INFO(CONFIG_BOOT_MSG_STRING "\n");
|
||||
}
|
||||
|
||||
main();
|
||||
int res = main();
|
||||
|
||||
if (IS_USED(MODULE_TEST_UTILS_MAIN_EXIT_CB)) {
|
||||
void test_utils_main_exit_cb(int res);
|
||||
test_utils_main_exit_cb(res);
|
||||
}
|
||||
|
||||
#ifdef MODULE_TEST_UTILS_PRINT_STACK_USAGE
|
||||
void print_stack_usage_metric(const char *name, void *stack, unsigned max_size);
|
||||
|
||||
@ -581,6 +581,7 @@ PSEUDOMODULES += crypto_aes_unroll
|
||||
|
||||
# declare shell version of test_utils_interactive_sync
|
||||
PSEUDOMODULES += test_utils_interactive_sync_shell
|
||||
PSEUDOMODULES += test_utils_main_exit_cb
|
||||
|
||||
# All auto_init modules are pseudomodules
|
||||
PSEUDOMODULES += auto_init_%
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user