You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by GitBox <gi...@apache.org> on 2018/01/10 14:58:32 UTC

[GitHub] rymanluk closed pull request #723: nimble/controller: Make sure random address is set correctly

rymanluk closed pull request #723: nimble/controller: Make sure random address is set correctly
URL: https://github.com/apache/mynewt-core/pull/723
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/net/nimble/controller/src/ble_ll_hci.c b/net/nimble/controller/src/ble_ll_hci.c
index 58bca9e3f..07e89a0b1 100644
--- a/net/nimble/controller/src/ble_ll_hci.c
+++ b/net/nimble/controller/src/ble_ll_hci.c
@@ -678,6 +678,13 @@ ble_ll_hci_le_cmd_proc(uint8_t *cmdbuf, uint16_t ocf, uint8_t *rsplen)
         break;
     case BLE_HCI_OCF_LE_SET_RAND_ADDR:
         rc = ble_ll_set_random_addr(cmdbuf);
+#if MYNEWT_VAL(BLE_EXT_ADV)
+        if (rc != BLE_ERR_SUCCESS) {
+            break;
+        }
+        /* For instance 0 we need same address */
+        rc = ble_ll_adv_set_random_addr(cmdbuf, 0);
+#endif
         break;
     case BLE_HCI_OCF_LE_SET_ADV_PARAMS:
         rc = ble_ll_adv_set_adv_params(cmdbuf);


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services