Skip to content

Commit 0ca62e4

Browse files
committed
Merge branch 'bugfix/fix_ag_return_result' into 'master'
bugfix/Fix error of AG API return line Closes BTCI-102 See merge request espressif/esp-idf!9565
2 parents 7639f20 + c40953f commit 0ca62e4

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

components/bt/host/bluedroid/api/esp_hf_ag_api.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ esp_err_t esp_bt_hf_vra(esp_bd_addr_t remote_addr, esp_hf_vr_state_t value)
179179

180180
/* Switch to BTC context */
181181
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), NULL);
182-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
182+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
183183
}
184184

185185
esp_err_t esp_bt_hf_volume_control(esp_bd_addr_t remote_addr, esp_hf_volume_control_target_t type, int volume)
@@ -200,7 +200,7 @@ esp_err_t esp_bt_hf_volume_control(esp_bd_addr_t remote_addr, esp_hf_volume_cont
200200

201201
/* Switch to BTC context */
202202
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), NULL);
203-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
203+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
204204
}
205205

206206
esp_err_t esp_hf_unat_response(esp_bd_addr_t remote_addr, char *unat)
@@ -220,7 +220,7 @@ esp_err_t esp_hf_unat_response(esp_bd_addr_t remote_addr, char *unat)
220220

221221
/* Switch to BTC context */
222222
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), btc_hf_arg_deep_copy);
223-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
223+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
224224
}
225225

226226
esp_err_t esp_bt_hf_cmee_response(esp_bd_addr_t remote_addr, esp_hf_at_response_code_t response_code, esp_hf_cme_err_t error_code)
@@ -241,7 +241,7 @@ esp_err_t esp_bt_hf_cmee_response(esp_bd_addr_t remote_addr, esp_hf_at_response_
241241

242242
/* Switch to BTC context */
243243
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), NULL);
244-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
244+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
245245
}
246246

247247
esp_err_t esp_bt_hf_indchange_notification(esp_bd_addr_t remote_addr,
@@ -368,7 +368,7 @@ esp_err_t esp_bt_hf_cnum_response(esp_bd_addr_t remote_addr, char *number, esp_h
368368

369369
/* Switch to BTC context */
370370
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), btc_hf_arg_deep_copy);
371-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
371+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
372372
}
373373

374374
esp_err_t esp_bt_hf_bsir(esp_bd_addr_t remote_addr, esp_hf_in_band_ring_state_t state)
@@ -388,7 +388,7 @@ esp_err_t esp_bt_hf_bsir(esp_bd_addr_t remote_addr, esp_hf_in_band_ring_state_t
388388

389389
/* Switch to BTC context */
390390
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), NULL);
391-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
391+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
392392
}
393393

394394
esp_err_t esp_bt_hf_answer_call(esp_bd_addr_t remote_addr, int num_active, int num_held,
@@ -415,7 +415,7 @@ esp_err_t esp_bt_hf_answer_call(esp_bd_addr_t remote_addr, int num_active, int n
415415

416416
/* Switch to BTC context */
417417
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), btc_hf_arg_deep_copy);
418-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
418+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
419419
}
420420

421421
esp_err_t esp_bt_hf_reject_call(esp_bd_addr_t remote_addr, int num_active, int num_held,
@@ -442,7 +442,7 @@ esp_err_t esp_bt_hf_reject_call(esp_bd_addr_t remote_addr, int num_active, int n
442442

443443
/* Switch to BTC context */
444444
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), btc_hf_arg_deep_copy);
445-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
445+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
446446
}
447447

448448
esp_err_t esp_bt_hf_end_call(esp_bd_addr_t remote_addr, int num_active, int num_held,
@@ -469,7 +469,7 @@ esp_err_t esp_bt_hf_end_call(esp_bd_addr_t remote_addr, int num_active, int num_
469469

470470
/* Switch to BTC context */
471471
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), btc_hf_arg_deep_copy);
472-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
472+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
473473
}
474474

475475
esp_err_t esp_bt_hf_out_call(esp_bd_addr_t remote_addr, int num_active, int num_held,
@@ -496,7 +496,7 @@ esp_err_t esp_bt_hf_out_call(esp_bd_addr_t remote_addr, int num_active, int num_
496496

497497
/* Switch to BTC context */
498498
bt_status_t status = btc_transfer_context(&msg, &arg, sizeof(btc_hf_args_t), btc_hf_arg_deep_copy);
499-
return (status = BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
499+
return (status == BT_STATUS_SUCCESS) ? ESP_OK : ESP_FAIL;
500500
}
501501

502502
esp_err_t esp_bt_hf_register_data_callback(esp_hf_incoming_data_cb_t recv, esp_hf_outgoing_data_cb_t send)

0 commit comments

Comments
 (0)