mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
core/init: set _native_retval to retval of main()
This commit is contained in:
parent
a613ff5831
commit
deaa17cc27
@ -74,6 +74,17 @@ static void *main_trampoline(void *arg)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef CPU_NATIVE
|
||||
extern unsigned _native_retval;
|
||||
if (!_native_retval) {
|
||||
_native_retval = res;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (IS_ACTIVE(CONFIG_CORE_EXIT_WITH_MAIN)) {
|
||||
pm_off();
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user