fix(posix): don't pthread_join the calling thread

This commit is contained in:
Julian Oes
2026-02-18 13:12:56 +13:00
committed by Ramon Roche
parent 2c599bf5cf
commit 4a51266488

View File

@@ -305,7 +305,6 @@ int px4_task_delete(px4_task_t id)
// If current thread then exit, otherwise cancel
if (pthread_self() == pid) {
pthread_join(pid, nullptr);
taskmap[id].isused = false;
pthread_mutex_unlock(&task_mutex);
pthread_exit(nullptr);