watcher: unregister a watcher FD if its thread gets cancelled