int count = 0;
APPL_TRACE_DEBUG("%s() - res: 0x%x", __func__, result);
- bta_sdp_cb.sdp_active = BTA_SDP_ACTIVE_NONE;
+ bta_sdp_cb.sdp_active = false;
if (bta_sdp_cb.p_dm_cback == NULL) return;
APPL_TRACE_DEBUG("%s in, sdp_active:%d", __func__, bta_sdp_cb.sdp_active);
- if (bta_sdp_cb.sdp_active != BTA_SDP_ACTIVE_NONE) {
+ if (bta_sdp_cb.sdp_active) {
/* SDP is still in progress */
status = BTA_SDP_BUSY;
if (bta_sdp_cb.p_dm_cback) {
return;
}
- bta_sdp_cb.sdp_active = BTA_SDP_ACTIVE_YES;
+ bta_sdp_cb.sdp_active = true;
bta_sdp_cb.remote_addr = bd_addr;
/* initialize the search for the uuid */
if (!SDP_ServiceSearchAttributeRequest2(bd_addr, p_bta_sdp_cfg->p_sdp_db,
bta_sdp_search_cback,
(void*)bta_sdp_search_uuid)) {
- bta_sdp_cb.sdp_active = BTA_SDP_ACTIVE_NONE;
+ bta_sdp_cb.sdp_active = false;
/* failed to start SDP. report the failure right away */
if (bta_sdp_cb.p_dm_cback) {
* Constants
****************************************************************************/
-enum {
- BTA_SDP_ACTIVE_NONE = 0,
- BTA_SDP_ACTIVE_YES /* waiting for SDP result */
-};
-
/* SDP control block */
typedef struct {
- uint8_t sdp_active; /* see BTA_SDP_SDP_ACT_* */
+ bool sdp_active;
RawAddress remote_addr;
tBTA_SDP_DM_CBACK* p_dm_cback;
} tBTA_SDP_CB;