From: Tom Tromey <tromey@redhat.com>
To: Pedro Alves <pedro@codesourcery.com>
Cc: gdb-patches@sourceware.org
Subject: Re: RFC: finish_command_continuation and errors
Date: Thu, 18 Mar 2010 17:59:00 -0000 [thread overview]
Message-ID: <m34okd340p.fsf@fleche.redhat.com> (raw)
In-Reply-To: <201003181728.30450.pedro@codesourcery.com> (Pedro Alves's message of "Thu, 18 Mar 2010 17:28:30 +0000")
>>>>> "Pedro" == Pedro Alves <pedro@codesourcery.com> writes:
>> This can happen if gdb calls error while printing the return value.
Pedro> For the record, can you show us which error was that?
In this case it was:
Value returned is $9 = warning: RTTI symbol not found for class 'java::lang::String'
Cannot access memory at address 0x0
Pedro> This probably also fixes frontends: the normal_stop observers
Pedro> notification call just a bit below was skipped too, which means
Pedro> the MI *stopped notification must have gone missing; a frontend
Pedro> was being left with no idea the thread had stopped. Could you
Pedro> check with your test, but running with -i=mi, that
Pedro> mi_on_normal_stop also isn't throwing an exception too in your
Pedro> case? I suspect not, but just in case. You can issue the normal
Pedro> CLI commands while in -i=mi to test this.
I tried this and it worked fine after my patch. From what I can see,
mi_on_normal_stop doesn't try to print the return value.
It seems to me that, abstractly, observers should not be allowed to
throw exceptions. Perhaps the observer machinery itself ought to catch
them. My reasoning is that letting an observer throw an exception will
make the observer mechanism apparently unreliable: a given observer
might or might not be called, depending on whether some earlier observer
encountered an error.
Tom
next prev parent reply other threads:[~2010-03-18 17:59 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-18 17:07 Tom Tromey
2010-03-18 17:35 ` Pedro Alves
2010-03-18 17:59 ` Tom Tromey [this message]
2010-03-18 18:08 ` Joel Brobecker
2010-03-18 18:14 ` Pedro Alves
2010-03-18 18:22 ` Tom Tromey
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=m34okd340p.fsf@fleche.redhat.com \
--to=tromey@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=pedro@codesourcery.com \
/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