Restore default signal handlers

This guarantees that the OS can handle further signals if, for example,
endwin() did not return.

Signed-off-by: Tristan Matthews <tristan.matthews@savoirfairelinux.com>
Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
Catch SIGQUIT and gracefully exit tig

Ctrl+4 sends a SIGQUIT to tig, which results in printing a
"Quit (core dumped)" message and leaving the console dirty.

This patch catches the signal in order to correctly end the session.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: Jonas Fonseca <fonseca@diku.dk>