Flush the log before quitting after SIGINT/SIGTERM

Signed-off-by: David Scott <dave.scott@eu.citrix.com>