projects
/
platform
/
upstream
/
bluez.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
301ab49
)
avdtp: fix possible minor problems
author
lishengyu
<lishengyu@uniontech.com>
Wed, 29 Jun 2022 12:46:56 +0000
(20:46 +0800)
committer
Ayush Garg
<ayush.garg@samsung.com>
Mon, 15 May 2023 09:25:54 +0000
(14:55 +0530)
It should always be considered that if send_request fails, sep
should be removed from the list and the requested memory freed;
Signed-off-by: Manika Shrivastava <manika.sh@samsung.com>
Signed-off-by: Ayush Garg <ayush.garg@samsung.com>
profiles/audio/avdtp.c
patch
|
blob
|
history
diff --git
a/profiles/audio/avdtp.c
b/profiles/audio/avdtp.c
index
53c85a5
..
2ce4f47
100644
(file)
--- a/
profiles/audio/avdtp.c
+++ b/
profiles/audio/avdtp.c
@@
-3293,8
+3293,11
@@
static gboolean avdtp_discover_resp(struct avdtp *session,
ret = send_request(session, TRUE, NULL, getcap_cmd,
&req, sizeof(req));
- if (ret < 0)
+ if (ret < 0) {
+ session->seps = g_slist_remove(session->seps, sep);
+ g_free(sep);
break;
+ }
getcap_pending = TRUE;
}