[PATCH 5.17 135/225] Bluetooth: hci_event: Fix checking for invalid handle on error status