Catch IllegalStateExceptions that are thrown when registering shut down hooks in the shut down phase of a JVM. Instead, kill the processes right away.

A user that calls destroyOnExit expects all external processes to be killed when the JVM is killed. Without this patch, processes might not get killed, when they are created in the shut down phase of a JVM. This might happen when:
 (a) The shut down hook was not yet registered
 (b) New processes are registered by other shut down hooks after this library's shut down was called.