Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tromey@redhat.com>
To: Marc Khouzam <marc.khouzam@ericsson.com>
Cc: "gdb-patches\@sourceware.org" <gdb-patches@sourceware.org>
Subject: Re: Assertion failure because of missing inferior
Date: Tue, 07 Dec 2010 18:54:00 -0000	[thread overview]
Message-ID: <m3bp4x8ldp.fsf@fleche.redhat.com> (raw)
In-Reply-To: <F7CE05678329534C957159168FA70DEC572E0C0DDD@EUSAACMS0703.eamcs.ericsson.se>	(Marc Khouzam's message of "Sat, 4 Dec 2010 14:10:54 -0500")

>>>>> "Marc" == Marc Khouzam <marc.khouzam@ericsson.com> writes:

Marc> So, I was thinking that since a frontend shouldn't care which
Marc> inferior is the current one, then '-remove-inferior' could change
Marc> the current inferior to another inferior, before doing the
Marc> removal.  This is pretty much what the frontend would have to do
Marc> anyway.  Removing the very last inferior would not be allowed.

Marc> The patch below does this.  What do you think of this approach?

This makes sense to me.

Marc> +/* Callback used to find the first inferior other than the
Marc> +   current one. */
Marc> +static int

Blank line between comment and function start.

Marc> +  if (inf == current_inferior ())
Marc> +    {
Marc> +      struct inferior *new_inferior = iterate_over_inferiors (get_other_inferior, NULL);

This line should be broken somewhere, probably before the '='.

Marc> +      if (new_inferior == NULL)
Marc> +       error ("Cannot remove last inferior");

Need _() around the text.

Tom


  reply	other threads:[~2010-12-07 18:54 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-04 19:11 Marc Khouzam
2010-12-07 18:54 ` Tom Tromey [this message]
2010-12-08  1:38   ` Marc Khouzam
2010-12-10 19:59     ` Tom Tromey
2010-12-10 20:21       ` Marc Khouzam
2010-12-10 21:01         ` Marc Khouzam
2010-12-10 21:38           ` Marc Khouzam
2010-12-14 14:50             ` Tom Tromey
2010-12-14 15:04               ` Joel Brobecker
2010-12-14 15:31                 ` Pedro Alves
2010-12-15  5:12                   ` Joel Brobecker
2010-12-14 20:00                 ` Marc Khouzam
2010-12-15 15:57                   ` [Python] Segfault when clearing pspace (was: RE: Assertion failure because of missing inferior) Marc Khouzam
2010-12-16 21:26                     ` [Python] Segfault when clearing pspace Tom Tromey
2010-12-18  2:13                       ` Marc Khouzam
2010-12-18  2:19               ` Assertion failure because of missing inferior Marc Khouzam
2010-12-14 14:49           ` 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=m3bp4x8ldp.fsf@fleche.redhat.com \
    --to=tromey@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=marc.khouzam@ericsson.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