i have a task that controls an external c library which has threads too.
when i press ctrl+c or shutdown via sigint i need to cleanly shutdown this task.
how can i get notified?