Fix a tasklets bug

The bug was reproducible by doing ^C while timer_test was running.