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/04/13 11:05:27 UTC
[mynewt-nimble] branch master updated: nimble/host: Fix error return in `ble_store_util_bonded_peers`
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 ebaeb570 nimble/host: Fix error return in `ble_store_util_bonded_peers`
ebaeb570 is described below
commit ebaeb57058ece3783b6098d6bd8906e4f0ae2311
Author: Prasad Alatkar <pr...@espressif.com>
AuthorDate: Wed Mar 10 20:02:14 2021 +0530
nimble/host: Fix error return in `ble_store_util_bonded_peers`
- When `max_peer`(input parameter) is less than stored bonds,
`ble_store_util_bonded_peers` returns `BLE_HS_ENOMEM` status code
unnecessarily. It results in non deletion of oldest bond when
`ble_gap_unpair_oldest_peer` is called.
---
nimble/host/src/ble_store_util.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/nimble/host/src/ble_store_util.c b/nimble/host/src/ble_store_util.c
index 7de48272..508fa00d 100644
--- a/nimble/host/src/ble_store_util.c
+++ b/nimble/host/src/ble_store_util.c
@@ -91,9 +91,6 @@ ble_store_util_bonded_peers(ble_addr_t *out_peer_id_addrs, int *out_num_peers,
if (rc != 0) {
return rc;
}
- if (set.status != 0) {
- return set.status;
- }
*out_num_peers = set.num_peers;
return 0;