OSDN Git Service

HFP: fix collision for the outgoing and incoming connection
authorweichinweng <weichinweng@google.com>
Wed, 11 Mar 2020 06:51:27 +0000 (14:51 +0800)
committerweichinweng <weichinweng@google.com>
Thu, 12 Mar 2020 06:02:09 +0000 (14:02 +0800)
commitcebcddd0ce5be3709bb92e6628997eecd59c25a0
tree96040a9cf3d36a9e28c5791c1294082b1cd360ba
parent4761c3e8b7e05938dd1233d46bd0748584223f47
HFP: fix collision for the outgoing and incoming connection

Since the HF incoming connection and the HF outgoing connection use the
same HF control block (p_scb) at the same time, the case will cause the
btif_hf_cb flag going wrong due to collision. Then it will trigger a
crash due to a check failure when executing BTA_AG_OPEN_EVT. The patch
will ignore the outgoing connection when the connection
collision is happening.

Bug: 143128949
Test: manual

Change-Id: Id5495bd3ecb1ed9e03de5bd74a61ab102604eaae
btif/src/btif_hf.cc