szymon-czapracki commented on code in PR #2019:
URL: https://github.com/apache/mynewt-nimble/pull/2019#discussion_r2048546623


##########
nimble/host/src/ble_eatt.c:
##########
@@ -219,39 +244,77 @@ ble_eatt_l2cap_event_fn(struct ble_l2cap_event *event, 
void *arg)
 {
     struct ble_eatt *eatt = arg;
     struct ble_gap_conn_desc desc;
+    uint8_t free_channels;
     uint8_t opcode;
     int rc;
 
     switch (event->type) {
     case BLE_L2CAP_EVENT_COC_CONNECTED:
-        BLE_EATT_LOG_DEBUG("eatt: Connected \n");
+        eatt = ble_eatt_find_by_conn_handle(event->connect.conn_handle);

Review Comment:
   Yes and no - eatt is passed when this funciton is called in setup_cb. But 
when server is running, and events are happening, eatt structure might be 
incomplete, as some of the fields are assigned as a result of event-handling 
within this function. Thus I thought to look if EATT exsists for specific 
connection - do you see a better solution here?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to