This fixes some minor issues that I noticed and fixed when adding partitioning to monitor. * Trap both INT as well as TERM. This allows you to use Ctrl+C to cleanly shutdown a respirate process started manually. * On apoptosis, exit 2 instead of 0, since I don't think apoptosis indicates success. * Avoid a potential race condition, where Kernel#exit is called concurrently by multiple threads. I don't think this matters on CRuby, but it's better to only exit in a single place, and have the thread update a variable to indicate clean shutdown.
3.5 KiB
Executable File
3.5 KiB
Executable File