You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ja...@apache.org on 2022/02/08 11:54:36 UTC

[mynewt-nimble] branch master updated: fix error: variable 'len' is used uninitialized when NDEBUG is defined

This is an automated email from the ASF dual-hosted git repository.

janc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-nimble.git


The following commit(s) were added to refs/heads/master by this push:
     new 0d0be63  fix error: variable 'len' is used uninitialized when NDEBUG is defined
0d0be63 is described below

commit 0d0be633dcdd2b9b09da3657a77c6861cd62e77c
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Thu Feb 3 12:48:20 2022 +0800

    fix error: variable 'len' is used uninitialized when NDEBUG is defined
    
    Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
---
 nimble/transport/socket/src/ble_hci_socket.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/nimble/transport/socket/src/ble_hci_socket.c b/nimble/transport/socket/src/ble_hci_socket.c
index b444a24..8a73389 100644
--- a/nimble/transport/socket/src/ble_hci_socket.c
+++ b/nimble/transport/socket/src/ble_hci_socket.c
@@ -357,6 +357,7 @@ ble_hci_sock_cmdevt_tx(uint8_t *hci_ev, uint8_t h4_type)
         STATS_INC(hci_sock_stats, oevt);
     } else {
         assert(0);
+        return BLE_ERR_UNKNOWN_HCI_CMD;
     }
     iov[1].iov_len = len;