OSDN Git Service

Properly handle outgoing connection requests in opening/opened state
authorAnubhav Gupta <anubhavg@codeaurora.org>
Wed, 4 Sep 2013 10:20:39 +0000 (15:50 +0530)
committerAndre Eisenbach <eisenbach@google.com>
Tue, 7 Jul 2015 07:09:49 +0000 (00:09 -0700)
commitfd0e9f1915dab624282c9d11ac6a1c7228c18c75
treef7d559f294a2fe28ae661a984454656610511e4e
parent905c72de29add7963b48e016b87e5ebe1a5f8503
Properly handle outgoing connection requests in opening/opened state

This happens in race conditions when we try to connect to a remote
A2DP device from Bluetooth Settings UI and simultaneously there is incoming
connection request from previously connected remote. This fix addresses
the scenario where because of first A2DP connection btif moves to opening/
opened state and then the second connect request is received.
This scenario is handled by gracefully rejecting the second connect request
from btif layer if it is already connected or about to be connected by the
first connect request.

Bug: 22028876
Change-Id: I53be400d1d7c9a84ca9d9a75b6b6f010975cf0cf
btif/src/btif_av.c