Added a signal handler harness that almost works correctly.