Skip to content

Commit

Permalink
remove loop for error handling
Browse files Browse the repository at this point in the history
  • Loading branch information
fabik111 committed Oct 29, 2024
1 parent 4292f8b commit f18645d
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ class HCIDriver : public CordioHCIDriver {
{
uint16_t cmd_len = service_pack_ptr[service_pack_index + 2];
uint16_t cmd_opcode = (service_pack_ptr[service_pack_index + 1] << 8) | service_pack_ptr[service_pack_index + 0];
uint8_t *pBuf = hciCmdAlloc(cmd_opcode, cmd_len);
uint8_t *pBuf = hciCmdAlloc(cmd_opcode, cmd_len);
if (pBuf) {
memcpy(pBuf + HCI_CMD_HDR_LEN, service_pack_ptr + service_pack_index + HCI_CMD_HDR_LEN, cmd_len);
inject_bdaddr(pBuf);
Expand All @@ -407,9 +407,9 @@ class HCIDriver : public CordioHCIDriver {

if (cmd_opcode != opcode) {
// DO something in case of error

while (true);

return;
}

// update service pack index
Expand Down

0 comments on commit f18645d

Please sign in to comment.