Add program destructor support

Update #4650.
This commit is contained in:
Sebastian Huber
2022-05-10 16:11:01 +02:00
parent a4c3d7468a
commit 7bc7bae957
3 changed files with 64 additions and 0 deletions

View File

@@ -60,6 +60,12 @@ rtems_bsd_program_call_main_with_data_restore(const char *name,
int (*main)(int, char **), int argc, char **argv,
void *data_buf, const size_t data_size);
void *
rtems_bsd_program_add_destructor(void (*destructor)(void *), void *arg);
void
rtems_bsd_program_remove_destructor(void *cookie, bool call);
void
rtems_bsd_program_exit(int exit_code) __dead2;