]> begriffs open source - freertos/commit
POSIX port - Cancel and join all FreeRTOS managed pthreads upon shutdown
authorChris Morgan <cmorgan@boston-engineering.com>
Tue, 28 Nov 2023 13:57:37 +0000 (08:57 -0500)
committerPaul Bartell <paul.bartell@gmail.com>
Thu, 11 Jan 2024 18:53:54 +0000 (10:53 -0800)
commit88d3540b54d837f1e06e9dd3837316ca5f425c14
tree9a2407338109ff279cc82fbe8532d44438fd16b4
parentddc89fa9851a85b1d5dfe40bfa9b84b5c1e514df
POSIX port - Cancel and join all FreeRTOS managed pthreads upon shutdown

For a clean shutdown where memory is freed, it is necessary for all pthreads to be joined
at shutdown.

Previously there was explicit cancellation of the idle task and timer daemon task, however
there may be a number of other tasks in the system, both system created and user created,
and those tasks/threads were being left at shutdown.

This change calls pthread_cancel()/pthread_join() on all FreeRTOS managed pthreads upon
shutdown.
portable/ThirdParty/GCC/Posix/port.c