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/04/09 08:03:33 UTC

[GitHub] rymanluk closed pull request #21: nimble/ll: Fix scanning handle for directed advertising

rymanluk closed pull request #21: nimble/ll: Fix scanning handle for directed advertising
URL: https://github.com/apache/mynewt-nimble/pull/21
 
 
   

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/nimble/controller/src/ble_ll_scan.c b/nimble/controller/src/ble_ll_scan.c
index 76559ef8..8f835a1c 100644
--- a/nimble/controller/src/ble_ll_scan.c
+++ b/nimble/controller/src/ble_ll_scan.c
@@ -758,12 +758,12 @@ ble_ll_scan_send_adv_report(uint8_t pdu_type, uint8_t txadd, struct os_mbuf *om,
 
     if (pdu_type == BLE_ADV_PDU_TYPE_ADV_DIRECT_IND) {
         inita = rxbuf + BLE_LL_PDU_HDR_LEN + BLE_DEV_ADDR_LEN;
-        if (!(inita[5] & 0x40)) {
-            /* Let's ignore it if address is not resolvable */
-            return;
+        if ((inita[5] & 0x40)) {
+            /* For resolvable we send separate event */
+            subev = BLE_HCI_LE_SUBEV_DIRECT_ADV_RPT;
+        } else {
+            subev = BLE_HCI_LE_SUBEV_ADV_RPT;
         }
-
-        subev = BLE_HCI_LE_SUBEV_DIRECT_ADV_RPT;
         evtype = BLE_HCI_ADV_RPT_EVTYPE_DIR_IND;
         event_len = BLE_HCI_LE_ADV_DIRECT_RPT_LEN;
         adv_data_len = 0;


 

----------------------------------------------------------------
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