Commit bbcd90bb authored by Vinayak Kariappa Chettimada's avatar Vinayak Kariappa Chettimada Committed by Chris Friedt
Browse files

Bluetooth: Controller: Use BT_HCI_ERR_UNSPECIFIED as needed

A Host shall consider any error code that it does not
explicitly understand equivalent to the error code
Unspecified Error (0x1F).

Signed-off-by: default avatarVinayak Kariappa Chettimada <vich@nordicsemi.no>
parent 98ec877f
Loading
Loading
Loading
Loading
+1 −1
Changes for subsys/bluetooth/controller/hci/hci.c: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -6330,7 +6330,7 @@ static void encrypt_change(uint8_t err, uint16_t handle,
	hci_evt_create(buf, BT_HCI_EVT_ENCRYPT_CHANGE, sizeof(*ep));
	ep = net_buf_add(buf, sizeof(*ep));

	ep->status = err;
	ep->status = err ? err : (encryption_on ? err : BT_HCI_ERR_UNSPECIFIED);
	ep->handle = sys_cpu_to_le16(handle);
	ep->encrypt = encryption_on ? 1 : 0;
}