Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jim Blandy <jimb@redhat.com>
To: Andrew Cagney <cagney@gnu.org>
Cc: gdb-patches@sources.redhat.com
Subject: Re: RFA: protect breakpoint commands from being freed
Date: Sat, 13 Dec 2003 22:42:00 -0000	[thread overview]
Message-ID: <vt2vfokl4uo.fsf@zenia.home> (raw)
In-Reply-To: <vt2llpgmqbu.fsf@zenia.home>

Jim Blandy <jimb@redhat.com> writes:

> Andrew Cagney <cagney@gnu.org> writes:
> 
> > > 2003-12-02  Jim Blandy  <jimb@redhat.com>
> > > 	* breakpoint.c (bpstat_do_actions): To ensure that
> > > 	clear_proceed_status doesn't free the command tree we're
> > > 	evaluating out from under us, zero the bpstat's pointer to it, and
> > > 	take care of freeing it ourselves.
> > > 	* cli/cli-script.c (make_cleanup_free_command_lines): Make this
> > > 	function externally visible.
> > > 	* cli/cli-script.h (make_cleanup_free_command_lines): New
> > > 	declaration.
> >
> > Didn't Don Howard fix this?
> 
> I remember Don Howard doing something related to this, but I it must
> have been a separate case.  The regression test I posted makes today's
> GDB crash.

Okay, I looked this up.  Don Howard posted a fix for a slightly
different problem --- the case where the breakpoint is deleted by its
own script.  The eventual solution entailed giving the bpstat its own
copy of the command tree.

The problem my patch addresses is distinct: GDB is freeing the
bpstat's copy before it is done with it.


  reply	other threads:[~2003-12-13 22:42 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-13  5:59 Jim Blandy
2003-12-13 18:56 ` Andrew Cagney
2003-12-13 20:13   ` Jim Blandy
2003-12-13 22:42     ` Jim Blandy [this message]
2003-12-17 18:32 ` Daniel Jacobowitz
2003-12-22  3:43   ` Jim Blandy

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=vt2vfokl4uo.fsf@zenia.home \
    --to=jimb@redhat.com \
    --cc=cagney@gnu.org \
    --cc=gdb-patches@sources.redhat.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