From gkruchio@gmail.com@21:1/5 to All on Mon Feb 13 02:06:04 2017
Hi,
reading the code of Thread_Timer_Queue_Test I can not find the deallocation of the Handler object if the timer is canceled.
I understand:
- Input_Task::add_timer() allocates a Handler and gives the Handler* pointer to Thread_Timer_Queue by calling its Thread_Timer_Queue::schedule() method
- in case of timer expiration Handler::handle_timeout() hook is called and the Handler is deleted
- in case of timer cancellation Thread_Timer_Queue::cancel() will be called.
I do *not* understand how Handler is deleted if Thread_Timer_Queue::cancel() is called before timer expiration.