cur_inst is the copy of ots_client instance to prevent duplicate API call while client is in middle of read/write procedure. But cur_inst can only be cleared while write_obj_tx_done or read rx_done. If ACL is disconnected while read/write is on-going, there is no chance for cur_inst being cleared. This causes ots client will no longer perform select/read/write procedure anymore. API will always return -EBUSY. Let l2cap_disconnect check if cur_inst is NULL and NULL it unconditionally as what it is designed. Make bt_ots_client_unregister public API. Signed-off-by: Pirun Lee <pirun.lee@nordicsemi.no> |
||
|---|---|---|
| .. | ||
| ias | ||
| ots | ||
| bas.c | ||
| CMakeLists.txt | ||
| dis.c | ||
| hrs.c | ||
| Kconfig | ||
| Kconfig.bas | ||
| Kconfig.dis | ||
| Kconfig.hrs | ||
| Kconfig.tps | ||
| tps.c | ||