pub fn register(f: impl Fn() + Send + Sync + 'static)
Registers a cleanup function to be executed when a Ctrl-C signal is received.