From c99ef49dcbff4ad1a316d7a38a2b152296c30ffc Mon Sep 17 00:00:00 2001 From: Matthew Xie Date: Thu, 18 Oct 2012 13:03:37 -0700 Subject: During call state change DIALING/ALERTING -> CONNECTED, donot redo SCO bug 7337252 Change-Id: Icd3ceada57c02887a9e5f3c850ebd7b5639111af --- bta/include/bta_ag_api.h | 6 ++++++ btif/src/btif_hf.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/bta/include/bta_ag_api.h b/bta/include/bta_ag_api.h index cc89374..f16687c 100644 --- a/bta/include/bta_ag_api.h +++ b/bta/include/bta_ag_api.h @@ -68,6 +68,12 @@ typedef UINT8 tBTA_AG_STATUS; /* handle values used with BTA_AgResult */ #define BTA_AG_HANDLE_NONE 0 #define BTA_AG_HANDLE_ALL 0xFFFF +/* It is safe to use the same value as BTA_AG_HANDLE_ALL + * HANDLE_ALL is used for delivering indication + * SCO_NO_CHANGE is used for changing sco behavior + * They donot interfere with each other + */ +#define BTA_AG_HANDLE_SCO_NO_CHANGE 0xFFFF /* AG result codes used with BTA_AgResult */ #define BTA_AG_SPK_RES 0 /* Update speaker volume */ diff --git a/btif/src/btif_hf.c b/btif/src/btif_hf.c index 49b0257..7ce22b1 100755 --- a/btif/src/btif_hf.c +++ b/btif/src/btif_hf.c @@ -992,7 +992,7 @@ static bt_status_t phone_state_change(int num_active, int num_held, bthf_call_st case BTHF_CALL_STATE_ALERTING: if (num_active > btif_hf_cb.num_active) { - ag_res.audio_handle = btif_hf_cb.handle; + ag_res.audio_handle = BTA_AG_HANDLE_SCO_NO_CHANGE; res = BTA_AG_OUT_CALL_CONN_RES; } else -- cgit v1.1