From: Daniel Jacobowitz <drow@false.org>
To: Vladimir Prus <ghost@cs.msu.su>
Cc: gdb@sources.redhat.com
Subject: Re: Reporting of "program no longer exists"
Date: Sat, 14 Oct 2006 16:39:00 -0000 [thread overview]
Message-ID: <20061014163911.GA16728@nevyn.them.org> (raw)
In-Reply-To: <200610142033.16596.ghost@cs.msu.su>
On Sat, Oct 14, 2006 at 08:33:16PM +0400, Vladimir Prus wrote:
>
> Hi,
> suppose a program being debugged got SIGSEGV and the user for GUI frontend
> tries the "next" command. Here's what happens:
>
> (gdb) -exec-next
> ^running
> *stopped,reason="signal-received",signal-name="SIGSEGV".....
> (gdb) -exec-next
> ^running
> Couldn't get registers: No such process.
> ^error,msg="Couldn't get registers: No such process."
This is simply a bug. Try it from the CLI:
(gdb) r
Starting program: /bin/cat
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
Program received signal SIGSEGV, Segmentation fault.
0x00002aaaaac7f352 in __read_nocancel () from /lib/libc.so.6
(gdb) n
Single stepping until exit from function __read_nocancel,
which has no line number information.
Program terminated with signal SIGSEGV, Segmentation fault.
The program no longer exists.
(gdb)
-exec-next ought to report ^running and then that the program has
exited (is that ^exited?). So I'd look at where the error came from.
> (1) How can frontend disable the "next" command? Checking for "SIGSEGV" is
> possible, but it a bit of a hack.
It's wrong. We don't know yet that the SIGSEGV will be fatal. If the
application has a signal handler installed for SIGSEGV, when you
continue the handler will be executed, and life will go on.
--
Daniel Jacobowitz
CodeSourcery
next prev parent reply other threads:[~2006-10-14 16:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-14 16:33 Vladimir Prus
2006-10-14 16:39 ` Daniel Jacobowitz [this message]
2006-10-14 20:58 ` Nick Roberts
2006-10-14 21:05 ` Daniel Jacobowitz
2006-10-14 21:17 ` Nick Roberts
2006-10-15 4:36 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20061014163911.GA16728@nevyn.them.org \
--to=drow@false.org \
--cc=gdb@sources.redhat.com \
--cc=ghost@cs.msu.su \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox