Date: Sun, 23 May 1999 13:07:47 +0300 (IDT) From: Eli Zaretskii X-Sender: eliz AT is To: Robert Hoehne , djgpp-workers AT delorie DOT com cc: Andris Pavenis Subject: Re: gdb 4.18 for DJGPP (alpha) In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp-workers AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk The latest dbgcom.c doesn't save and restore SIGQUIT across debuggee invocations. I think this might make trouble if the debuggee enables SIGQUIT. At least when I linked GDB with the v2.02 version of dbgcom.c and pressed Ctrl-\ after running the debuggee, GDB crashed and took CWSDPMI with it (and the registers' dump clearly indicated that ES and GS came from the debuggee). The patch is below (it might not apply cleanly, since I ran diff against v2.02 sources); if there are no objections, I will check it in. *** src/debug/common/dbgcom.c~0 Sun Jun 28 22:37:44 1998 --- src/debug/common/dbgcom.c Fri May 21 16:36:28 1999 *************** static void (*oldTRAP)(int); *** 610,615 **** --- 610,616 ---- static void (*oldSEGV)(int); static void (*oldFPE)(int); static void (*oldINT)(int); + static void (*oldQUIT)(int); void edi_init(jmp_buf start_state) { *************** void edi_init(jmp_buf start_state) *** 637,642 **** --- 638,644 ---- oldSEGV = signal(SIGSEGV, dbgsig); oldFPE = signal(SIGFPE, dbgsig); oldINT = signal(SIGINT, dbgsig); + oldQUIT = signal(SIGQUIT, dbgsig); movedata(a_tss.tss_fs,0,my_ds,(unsigned)&si,sizeof(si)); memset(mem_handles,0,sizeof(mem_handles)); mem_handles[0] = si.memory_handle; *************** void cleanup_client(void) *** 696,701 **** --- 698,704 ---- signal(SIGSEGV, oldSEGV); signal(SIGFPE, oldFPE); signal(SIGINT, oldINT); + signal(SIGQUIT, oldQUIT); } /*