system/bt
修订版 | 6097686fc7e49c096737e1c9dd089b3e14483f27 (tree) |
---|---|
时间 | 2019-06-01 03:12:11 |
作者 | Android Build Merger (Role) <noreply-android-build-merger@goog...> |
Commiter | Android Build Merger (Role) |
[automerger] DO NOT MERGE: btif: require pairing dialog for JustWorks SSP am: 042fe6394c am: c80a6ed6e6
Change-Id: Iaee48fb07517f32ea191eff26f359eca7151cd38
@@ -980,7 +980,6 @@ static void btif_dm_ssp_cfm_req_evt(tBTA_DM_SP_CFM_REQ *p_ssp_cfm_req) | ||
980 | 980 | bt_bdaddr_t bd_addr; |
981 | 981 | bt_bdname_t bd_name; |
982 | 982 | UINT32 cod; |
983 | - BOOLEAN is_incoming = !(pairing_cb.state == BT_BOND_STATE_BONDING); | |
984 | 983 | int dev_type; |
985 | 984 | |
986 | 985 | BTIF_TRACE_DEBUG("%s", __FUNCTION__); |
@@ -1011,30 +1010,6 @@ static void btif_dm_ssp_cfm_req_evt(tBTA_DM_SP_CFM_REQ *p_ssp_cfm_req) | ||
1011 | 1010 | |
1012 | 1011 | pairing_cb.is_ssp = TRUE; |
1013 | 1012 | |
1014 | - /* If JustWorks auto-accept */ | |
1015 | - if (p_ssp_cfm_req->just_works) | |
1016 | - { | |
1017 | - /* Pairing consent for JustWorks needed if: | |
1018 | - * 1. Incoming (non-temporary) pairing is detected AND | |
1019 | - * 2. local IO capabilities are DisplayYesNo AND | |
1020 | - * 3. remote IO capabiltiies are DisplayOnly or NoInputNoOutput; | |
1021 | - */ | |
1022 | - if (is_incoming && pairing_cb.bond_type != BOND_TYPE_TEMPORARY && | |
1023 | - ((p_ssp_cfm_req->loc_io_caps == HCI_IO_CAP_DISPLAY_YESNO) && | |
1024 | - (p_ssp_cfm_req->rmt_io_caps == HCI_IO_CAP_DISPLAY_ONLY || | |
1025 | - p_ssp_cfm_req->rmt_io_caps == HCI_IO_CAP_NO_IO))) | |
1026 | - { | |
1027 | - BTIF_TRACE_EVENT("%s: User consent needed for incoming pairing request. loc_io_caps: %d, rmt_io_caps: %d", | |
1028 | - __FUNCTION__, p_ssp_cfm_req->loc_io_caps, p_ssp_cfm_req->rmt_io_caps); | |
1029 | - } | |
1030 | - else | |
1031 | - { | |
1032 | - BTIF_TRACE_EVENT("%s: Auto-accept JustWorks pairing", __FUNCTION__); | |
1033 | - btif_dm_ssp_reply(&bd_addr, BT_SSP_VARIANT_CONSENT, TRUE, 0); | |
1034 | - return; | |
1035 | - } | |
1036 | - } | |
1037 | - | |
1038 | 1013 | cod = devclass2uint(p_ssp_cfm_req->dev_class); |
1039 | 1014 | |
1040 | 1015 | if (cod == 0) { |