diff --git a/net/bluetooth/bluetooth_sendmsg.c b/net/bluetooth/bluetooth_sendmsg.c index 4c4e6dd4cb8..20ea320a585 100644 --- a/net/bluetooth/bluetooth_sendmsg.c +++ b/net/bluetooth/bluetooth_sendmsg.c @@ -284,12 +284,12 @@ static ssize_t bluetooth_sendto(FAR struct socket *psock, radio = (FAR struct radio_driver_s *)netdev_findbyindex(conn->bc_ldev + 1); - DEBUGASSERT(radio->r_dev.d_lltype == NET_LL_BLUETOOTH); - if (radio == NULL) { return -ENODEV; } + + DEBUGASSERT(radio->r_dev.d_lltype == NET_LL_BLUETOOTH); } else {