* [PATCH] android: Fix memory leak: uuid free
@ 2014-02-12 14:22 Andrei Emeltchenko
2014-02-14 9:01 ` Andrei Emeltchenko
2014-02-14 10:36 ` Szymon Janc
0 siblings, 2 replies; 3+ messages in thread
From: Andrei Emeltchenko @ 2014-02-12 14:22 UTC (permalink / raw)
To: linux-bluetooth
From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
Free uuid before exiting.
---
android/bluetooth.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/android/bluetooth.c b/android/bluetooth.c
index 5de3401..b818e88 100644
--- a/android/bluetooth.c
+++ b/android/bluetooth.c
@@ -1557,6 +1557,8 @@ int bt_adapter_add_record(sdp_record_t *rec, uint8_t svc_hint)
sdp_uuid2strn(uuid, uuid_str, sizeof(uuid_str));
DBG("UUID %s already added", uuid_str);
+
+ bt_free(uuid);
return -EALREADY;
}
--
1.8.3.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] android: Fix memory leak: uuid free
2014-02-12 14:22 [PATCH] android: Fix memory leak: uuid free Andrei Emeltchenko
@ 2014-02-14 9:01 ` Andrei Emeltchenko
2014-02-14 10:36 ` Szymon Janc
1 sibling, 0 replies; 3+ messages in thread
From: Andrei Emeltchenko @ 2014-02-14 9:01 UTC (permalink / raw)
To: linux-bluetooth
On Wed, Feb 12, 2014 at 04:22:07PM +0200, Andrei Emeltchenko wrote:
> From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
>
> Free uuid before exiting.
ping
> ---
> android/bluetooth.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/android/bluetooth.c b/android/bluetooth.c
> index 5de3401..b818e88 100644
> --- a/android/bluetooth.c
> +++ b/android/bluetooth.c
> @@ -1557,6 +1557,8 @@ int bt_adapter_add_record(sdp_record_t *rec, uint8_t svc_hint)
>
> sdp_uuid2strn(uuid, uuid_str, sizeof(uuid_str));
> DBG("UUID %s already added", uuid_str);
> +
> + bt_free(uuid);
> return -EALREADY;
> }
>
> --
> 1.8.3.2
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] android: Fix memory leak: uuid free
2014-02-12 14:22 [PATCH] android: Fix memory leak: uuid free Andrei Emeltchenko
2014-02-14 9:01 ` Andrei Emeltchenko
@ 2014-02-14 10:36 ` Szymon Janc
1 sibling, 0 replies; 3+ messages in thread
From: Szymon Janc @ 2014-02-14 10:36 UTC (permalink / raw)
To: Andrei Emeltchenko; +Cc: linux-bluetooth
Hi Andrei,
On Wednesday 12 of February 2014 16:22:07 Andrei Emeltchenko wrote:
> From: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
>
> Free uuid before exiting.
> ---
> android/bluetooth.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/android/bluetooth.c b/android/bluetooth.c
> index 5de3401..b818e88 100644
> --- a/android/bluetooth.c
> +++ b/android/bluetooth.c
> @@ -1557,6 +1557,8 @@ int bt_adapter_add_record(sdp_record_t *rec, uint8_t svc_hint)
>
> sdp_uuid2strn(uuid, uuid_str, sizeof(uuid_str));
> DBG("UUID %s already added", uuid_str);
> +
> + bt_free(uuid);
> return -EALREADY;
> }
Applied, thanks.
--
Best regards,
Szymon Janc
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-02-14 10:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-12 14:22 [PATCH] android: Fix memory leak: uuid free Andrei Emeltchenko
2014-02-14 9:01 ` Andrei Emeltchenko
2014-02-14 10:36 ` Szymon Janc
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.