linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johan Hedberg <johan.hedberg@gmail.com>
To: Claudio Takahasi <claudio.takahasi@openbossa.org>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: [PATCH BlueZ] Fix invalid free when stopping adapter
Date: Tue, 27 Sep 2011 12:16:56 +0300	[thread overview]
Message-ID: <20110927091655.GP3952@dell> (raw)
In-Reply-To: <1316527880-8081-1-git-send-email-claudio.takahasi@openbossa.org>

Hi Claudio,

On Tue, Sep 20, 2011, Claudio Takahasi wrote:
> This patch fix an "invalid free" error when the adapter is powered off
> with an active discovery session. Error happens because session_remove
> function removes the elements from the list also. Partial valgrind log:
> Address 0x6012a00 is 0 bytes inside a block of size 16 free'd
>   at 0x4C27DCC: free (vg_replace_malloc.c:366)
>   by 0x4E927AC: g_slist_remove (in
>   by 0x19F788: session_remove (adapter.c:689)
>   by 0x19F82A: session_free (adapter.c:708)
>   by 0x4E92CD6: g_slist_foreach (in
>   by 0x4E92CFA: g_slist_free_full (in
>   by 0x1A3ADD: btd_adapter_stop (adapter.c:2491)
> ---
>  src/adapter.c |   20 +++++++++++++-------
>  1 files changed, 13 insertions(+), 7 deletions(-)

Applied. Thanks.

Johan

      parent reply	other threads:[~2011-09-27  9:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-20 14:11 [PATCH BlueZ] Fix invalid free when stopping adapter Claudio Takahasi
2011-09-20 14:44 ` Luiz Augusto von Dentz
2011-09-20 14:58   ` Claudio Takahasi
2011-09-27  9:16 ` Johan Hedberg [this message]

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=20110927091655.GP3952@dell \
    --to=johan.hedberg@gmail.com \
    --cc=claudio.takahasi@openbossa.org \
    --cc=linux-bluetooth@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).