diff options
Diffstat (limited to 'src/time/timer_delete.c')
-rw-r--r-- | src/time/timer_delete.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/time/timer_delete.c b/src/time/timer_delete.c index f05b27d5..b5f8ca19 100644 --- a/src/time/timer_delete.c +++ b/src/time/timer_delete.c @@ -3,6 +3,11 @@ int timer_delete(timer_t t) { - if ((uintptr_t)t >= 0x100000) return pthread_cancel(t); + if ((uintptr_t)t >= 0x100000) { + pthread_t td = t; + td->delete_timer = 1; + __wake(&td->delete_timer, 1, 1); + return 0; + } return __syscall(SYS_timer_delete, (long)t); } |