Skip to content

Commit

Permalink
Fix bad GATT client state machine state after successfull cache load
Browse files Browse the repository at this point in the history
If the GATT service cache was successfully loaded from a file, the
state must be reset to idle.

Bug: 31175159
Change-Id: I92ebf1bec9d2e7467d7412b41923614ec5a13b6d
  • Loading branch information
Jakub Pawlowski committed Oct 3, 2016
1 parent 013c32b commit f87953f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions bta/gatt/bta_gattc_act.c
Original file line number Diff line number Diff line change
Expand Up @@ -715,6 +715,7 @@ void bta_gattc_conn(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
{
p_clcb->p_srcb->state = BTA_GATTC_SERV_LOAD;
if (bta_gattc_cache_load(p_clcb)) {
p_clcb->p_srcb->state = BTA_GATTC_SERV_IDLE;
bta_gattc_reset_discover_st(p_clcb->p_srcb, BTA_GATT_OK);
} else {
p_clcb->p_srcb->state = BTA_GATTC_SERV_DISC;
Expand Down

0 comments on commit f87953f

Please sign in to comment.