Skip to content

Commit 1cfd624

Browse files
lylezhu2012kartben
authored andcommitted
Bluetooth: SDP: Notify upper layer if the response data len is 0
In current implementation, the SDP discovery complete event is not notified when the response data length is 0. Notify the discovery complete event if the response length is 0. Signed-off-by: Lyle Zhu <[email protected]>
1 parent de7405d commit 1cfd624

File tree

1 file changed

+1
-1
lines changed
  • subsys/bluetooth/host/classic

1 file changed

+1
-1
lines changed

subsys/bluetooth/host/classic/sdp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1818,7 +1818,7 @@ static void sdp_client_notify_result(struct bt_sdp_client *session,
18181818
uint16_t rec_len;
18191819
uint8_t user_ret;
18201820

1821-
if (state == UUID_NOT_RESOLVED) {
1821+
if ((state == UUID_NOT_RESOLVED) || (session->rec_buf->len == 0U)) {
18221822
result.resp_buf = NULL;
18231823
result.next_record_hint = false;
18241824
session->param->func(conn, &result, session->param);

0 commit comments

Comments
 (0)