Decelerate shutdown process for one second.
authorStefan Schantl <stefan.schantl@ipfire.org>
Wed, 25 Nov 2015 08:24:54 +0000 (09:24 +0100)
committerStefan Schantl <stefan.schantl@ipfire.org>
Wed, 25 Nov 2015 08:24:54 +0000 (09:24 +0100)
When shutting down guardian the function now will pause for
one second to give perl some more time to proper clean up
everything before finally exiting the process.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
guardian

index cf759b0..2326684 100644 (file)
--- a/guardian
+++ b/guardian
@@ -311,6 +311,11 @@ sub Shutdown () {
        # Remove socket file on exit.
        &Guardian::Socket::RemoveSocketFile();
 
+       # Sleep for one second to give perl some
+       # time to proper clean up everything before
+       # exiting.
+       sleep(1);
+
        # Exit guardian.
        exit;
 }