From ce23ec312098e974a77f35d3df35bd607d9efde0 Mon Sep 17 00:00:00 2001 From: Vincent Coubard Date: Mon, 19 Sep 2016 13:54:50 +0100 Subject: [PATCH] Disable registration of __libc_fini_array in the init process. With this call, destructors are not registered for execution atexit. --- rtos/rtx/TARGET_CORTEX_M/RTX_CM_lib.h | 1 - 1 file changed, 1 deletion(-) diff --git a/rtos/rtx/TARGET_CORTEX_M/RTX_CM_lib.h b/rtos/rtx/TARGET_CORTEX_M/RTX_CM_lib.h index d7f0117cf0..e1633f74d7 100644 --- a/rtos/rtx/TARGET_CORTEX_M/RTX_CM_lib.h +++ b/rtos/rtx/TARGET_CORTEX_M/RTX_CM_lib.h @@ -798,7 +798,6 @@ void pre_main(void) { singleton_mutex_id = osMutexCreate(osMutex(singleton_mutex)); malloc_mutex_id = osMutexCreate(osMutex(malloc_mutex)); env_mutex_id = osMutexCreate(osMutex(env_mutex)); - atexit(__libc_fini_array); __libc_init_array(); main(0, NULL); }