From: Bharat Panda Date: Fri, 13 Nov 2015 13:24:19 +0000 (+0530) Subject: audio/avdtp: Fix added first endpoints X-Git-Tag: accepted/tizen/mobile/20151202.230855~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4308548cc560a89a9f15fe577f0a51d0435c2a87;p=platform%2Fupstream%2Fbluez.git audio/avdtp: Fix added first endpoints This resolves suspending and resuming only the first SEID. Changes taken only for linux bluez, excluded android part of fix. AVDTP_Start can contain several Stream Endpoing IDs to be resumed. AVDTP_Suspend can contain several Stream Endpoing IDs to be suspended. git repo link: http://git.kernel.org/cgit/bluetooth/bluez.git/commit/?id=b5c6b1ed97ee6fe03092223c5f4ba8800a186519 http://git.kernel.org/cgit/bluetooth/bluez.git/commit/?id=302e4163f39e87fe6ab951bc2e2eb322b43ed6cd Change-Id: I5f63eeae8b901d39782855205aad00b34b32a762 --- diff --git a/profiles/audio/avdtp.c b/profiles/audio/avdtp.c index aba2d03..481991e 100644 --- a/profiles/audio/avdtp.c +++ b/profiles/audio/avdtp.c @@ -1932,8 +1932,7 @@ static gboolean avdtp_start_cmd(struct avdtp *session, uint8_t transaction, for (i = 0; i < seid_count; i++, seid++) { failed_seid = seid->seid; - sep = find_local_sep_by_seid(session, - req->first_seid.seid); + sep = find_local_sep_by_seid(session, seid->seid); if (!sep || !sep->stream) { err = AVDTP_BAD_ACP_SEID; goto failed; @@ -2044,8 +2043,7 @@ static gboolean avdtp_suspend_cmd(struct avdtp *session, uint8_t transaction, for (i = 0; i < seid_count; i++, seid++) { failed_seid = seid->seid; - sep = find_local_sep_by_seid(session, - req->first_seid.seid); + sep = find_local_sep_by_seid(session, seid->seid); if (!sep || !sep->stream) { err = AVDTP_BAD_ACP_SEID; goto failed;