Skip to content

Commit d37402f

Browse files
lylezhu2012kartben
authored andcommitted
Bluetooth: Shell: BR: Update command sdp-find
Since the function `bt_sdp_discover` has been updated, the caller of function needs to be updated to avoid the building and functionality fault. Add set the parameter `type` to value `BT_SDP_DISCOVER_SERVICE_SEARCH_ATTR`. Update the SDP discovery callback function. Make it align with `bt_sdp_discover_func_t`. Signed-off-by: Lyle Zhu <[email protected]>
1 parent a047113 commit d37402f

File tree

1 file changed

+6
-2
lines changed
  • subsys/bluetooth/host/classic/shell

1 file changed

+6
-2
lines changed

subsys/bluetooth/host/classic/shell/bredr.c

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,8 @@ static int cmd_oob(const struct shell *sh, size_t argc, char *argv[])
370370
}
371371

372372
static uint8_t sdp_hfp_ag_user(struct bt_conn *conn,
373-
struct bt_sdp_client_result *result)
373+
struct bt_sdp_client_result *result,
374+
const struct bt_sdp_discover_params *params)
374375
{
375376
char addr[BT_ADDR_STR_LEN];
376377
uint16_t param, version;
@@ -429,7 +430,8 @@ static uint8_t sdp_hfp_ag_user(struct bt_conn *conn,
429430
}
430431

431432
static uint8_t sdp_a2src_user(struct bt_conn *conn,
432-
struct bt_sdp_client_result *result)
433+
struct bt_sdp_client_result *result,
434+
const struct bt_sdp_discover_params *params)
433435
{
434436
char addr[BT_ADDR_STR_LEN];
435437
uint16_t param, version;
@@ -494,12 +496,14 @@ static uint8_t sdp_a2src_user(struct bt_conn *conn,
494496
}
495497

496498
static struct bt_sdp_discover_params discov_hfpag = {
499+
.type = BT_SDP_DISCOVER_SERVICE_SEARCH_ATTR,
497500
.uuid = BT_UUID_DECLARE_16(BT_SDP_HANDSFREE_AGW_SVCLASS),
498501
.func = sdp_hfp_ag_user,
499502
.pool = &sdp_client_pool,
500503
};
501504

502505
static struct bt_sdp_discover_params discov_a2src = {
506+
.type = BT_SDP_DISCOVER_SERVICE_SEARCH_ATTR,
503507
.uuid = BT_UUID_DECLARE_16(BT_SDP_AUDIO_SOURCE_SVCLASS),
504508
.func = sdp_a2src_user,
505509
.pool = &sdp_client_pool,

0 commit comments

Comments
 (0)