[PATCH 3/6] android/gatt: Simplify discover_char_cb

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



---
 android/gatt.c | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/android/gatt.c b/android/gatt.c
index 67bb9b5..18f1a37 100644
--- a/android/gatt.c
+++ b/android/gatt.c
@@ -1792,12 +1792,13 @@ static void discover_char_cb(uint8_t status, GSList *characteristics,
 								void *user_data)
 {
 	struct discover_char_data *data = user_data;
+	struct service *srvc = data->service;
 
-	if (queue_isempty(data->service->chars))
-		cache_all_srvc_chars(data->service, characteristics);
+	if (queue_isempty(srvc->chars))
+		cache_all_srvc_chars(srvc, characteristics);
 
-	send_client_char_notify(queue_peek_head(data->service->chars),
-						data->conn_id, data->service);
+	send_client_char_notify(queue_peek_head(srvc->chars), data->conn_id,
+									srvc);
 
 	free(data);
 }
-- 
1.9.2

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux