Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Sterling Augustine <saugustine@google.com>
To: Tom Tromey <tromey@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [Patch] More responsive QUITs
Date: Mon, 25 Jul 2011 21:07:00 -0000	[thread overview]
Message-ID: <CAEG7qUzPFNZWLeE78Ri_VfvDhk8+RsRkFJK9fNSGkGkmRK1h6w@mail.gmail.com> (raw)
In-Reply-To: <m3wrf6qeii.fsf@fleche.redhat.com>

On Mon, Jul 25, 2011 at 1:41 PM, Tom Tromey <tromey@redhat.com> wrote:
> Sterling> New revision of the patch which addresses this issue attached.
>
> You forgot to CC the list :)
>
> Sterling> +  struct cleanup *back_to;
>
> Sterling>    list[0] = NULL;
>
> Sterling>    if (!have_full_symbols () && !have_partial_symbols ())
> Sterling>      return list;
>
> Sterling> +  back_to = make_cleanup (xfree, list);
>
> This captures 'list' at this point in time, but list can be reallocated.
> See add_filename_to_list.

Will work on a fix for this.

> Also, each element of list is itself mallocd and so must be freed.

The calling function (completer.c:308 and below) doesn't free the
individual elements either, so there is a more general gdb leak. I'll
fix both.

Sterling


  parent reply	other threads:[~2011-07-25 20:58 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-13  3:03 Sterling Augustine
2011-07-15 20:49 ` Tom Tromey
2011-07-20 18:46   ` Sterling Augustine
2011-07-22  1:14     ` Tom Tromey
     [not found]       ` <CAEG7qUxKevmBX=oCXr2p+x-zi-ZbBGLf3Gmb-X2bnVBpf7VKGA@mail.gmail.com>
     [not found]         ` <m3wrf6qeii.fsf@fleche.redhat.com>
2011-07-25 21:07           ` Sterling Augustine [this message]
2011-07-25 21:41             ` 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=CAEG7qUzPFNZWLeE78Ri_VfvDhk8+RsRkFJK9fNSGkGkmRK1h6w@mail.gmail.com \
    --to=saugustine@google.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@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