You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by cc...@apache.org on 2016/07/13 20:55:34 UTC

[21/50] [abbrv] incubator-mynewt-core git commit: BLE Host - ble_gap_conn_cancel() - rc when !active

BLE Host - ble_gap_conn_cancel() - rc when !active

Previously this returned BLE_HS_ENOENT
Now it returns BLE_HS_EALREADY.


Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/16e98716
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/16e98716
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/16e98716

Branch: refs/heads/develop
Commit: 16e987169b63ae3eb3fa50de609f0442bd774146
Parents: 270fcf6
Author: Christopher Collins <cc...@apache.org>
Authored: Thu Jun 30 17:23:14 2016 -0700
Committer: Christopher Collins <cc...@apache.org>
Committed: Mon Jul 11 16:43:33 2016 -0700

----------------------------------------------------------------------
 net/nimble/host/src/ble_gap.c           | 2 +-
 net/nimble/host/src/test/ble_gap_test.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/16e98716/net/nimble/host/src/ble_gap.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_gap.c b/net/nimble/host/src/ble_gap.c
index c3df545..78e8ac1 100644
--- a/net/nimble/host/src/ble_gap.c
+++ b/net/nimble/host/src/ble_gap.c
@@ -2199,7 +2199,7 @@ ble_gap_conn_cancel(void)
     ble_hs_lock();
 
     if (!ble_gap_master_in_progress()) {
-        rc = BLE_HS_ENOENT;
+        rc = BLE_HS_EALREADY;
         goto done;
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/16e98716/net/nimble/host/src/test/ble_gap_test.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/test/ble_gap_test.c b/net/nimble/host/src/test/ble_gap_test.c
index dd8d78a..bb08bd0 100644
--- a/net/nimble/host/src/test/ble_gap_test.c
+++ b/net/nimble/host/src/test/ble_gap_test.c
@@ -914,7 +914,7 @@ TEST_CASE(ble_gap_test_case_conn_cancel_bad_args)
     /* Initiate cancel procedure with no connection in progress. */
     TEST_ASSERT(!ble_gap_master_in_progress());
     rc = ble_hs_test_util_conn_cancel(0);
-    TEST_ASSERT(rc == BLE_HS_ENOENT);
+    TEST_ASSERT(rc == BLE_HS_EALREADY);
 }
 
 TEST_CASE(ble_gap_test_case_conn_cancel_good)