Skip to content

Commit 07b0b0d

Browse files
MariuszSkamraandrzej-kaczmarek
authored andcommitted
nimble/host: Fix unexpected assertion
This fixes unexpected assertion that happens before mutex lock. The caller shall wait on mutex instead, when ack is pending.
1 parent 9c3ad28 commit 07b0b0d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

nimble/host/src/ble_hs_hci.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,8 +313,8 @@ ble_hs_hci_cmd_tx(uint16_t opcode, const void *cmd, uint8_t cmd_len,
313313
struct ble_hs_hci_ack ack;
314314
int rc;
315315

316-
BLE_HS_DBG_ASSERT(ble_hs_hci_ack == NULL);
317316
ble_hs_hci_lock();
317+
BLE_HS_DBG_ASSERT(ble_hs_hci_ack == NULL);
318318

319319
rc = ble_hs_hci_cmd_send_buf(opcode, cmd, cmd_len);
320320
if (rc != 0) {

0 commit comments

Comments
 (0)