From 16a43bf443c8e2ab7fc9d35e131d6a3d773149b6 Mon Sep 17 00:00:00 2001 From: Dawn Perchik Date: Wed, 12 Feb 1997 10:27:11 +0000 Subject: * defs.h: Fix cntl-C to read from the Windows message queue. Add prototypes for make_final_cleanup (and the other cleanup routines. * remote-e7000.c: Fix sync code to timeout if unable to sync. Change sync code to report status while trying to sync-up with hardware. Add debugging output and document. * ser-e7kpc.c: Swap order of len & offset to match implementation. Add debugging output and document. * serial.c: Add debugging output. * top.c: Add call to do_final_cleanups. Remove conditionals preventing Win32 from getting SIGQUIT. * utils.c: (*_cleanup): Modify cleanup routines to accept a cleanup chain as a parameter. Extract this generic code from the cleanup routines into separate funtions (*_my_cleanup). Keep old functionality by passing "cleanup_chain" to the new funtions. Define the cleanup chain "final_cleanup_chain" to be a cleanup chain which will be executed only when gdb exits. Add functions (*_final_cleanup) to match the original (*_cleanup) functions. (pollquit, quit, notice_quit): Fix to read cntl-C from the Windows message queue. --- gdb/top.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'gdb/top.c') diff --git a/gdb/top.c b/gdb/top.c index 2e1098c..3afa8c9 100644 --- a/gdb/top.c +++ b/gdb/top.c @@ -571,7 +571,6 @@ catch_errors (func, args, errstring, mask) /* Handler for SIGHUP. */ -#ifndef _WIN32 static void disconnect (signo) int signo; @@ -581,7 +580,6 @@ int signo; signal (SIGHUP, SIG_DFL); kill (getpid (), SIGHUP); } -#endif /* Just a little helper function for disconnect(). */ @@ -1899,11 +1897,9 @@ init_signals () might be in memory, shared between the two). Since we establish a handler for SIGQUIT, when we call exec it will set the signal to SIG_DFL for us. */ -#ifndef _WIN32 signal (SIGQUIT, do_nothing); if (signal (SIGHUP, do_nothing) != SIG_IGN) signal (SIGHUP, disconnect); -#endif signal (SIGFPE, float_handler); #if defined(SIGWINCH) && defined(SIGWINCH_HANDLER) @@ -2856,6 +2852,8 @@ quit_command (args, from_tty) if (write_history_p && history_filename) write_history (history_filename); + do_final_cleanups(ALL_CLEANUPS); /* Do any final cleanups before exiting */ + exit (exit_code); } -- cgit v1.1