Diff between 1ea6892cc66302c2d3e41f90c89f3e052fb25ddc and ef2bada479e21d981741a5b467cc70961e219ac1

Changed Files

File Additions Deletions Status
src/shared/gatt-client.c +4 -0 modified

Full Patch

diff --git a/src/shared/gatt-client.c b/src/shared/gatt-client.c
index 41df669..6ca027f 100644
--- a/src/shared/gatt-client.c
+++ b/src/shared/gatt-client.c
@@ -893,6 +893,8 @@ static void exchange_mtu_cb(bool success, uint8_t att_ecode, void *user_data)
 	struct discovery_op *op = user_data;
 	struct bt_gatt_client *client = op->client;
 
+	op->success = success;
+
 	if (!success) {
 		util_debug(client->debug_callback, client->debug_data,
 				"MTU Exchange failed. ATT ECODE: 0x%02x",
@@ -1188,6 +1190,8 @@ fail:
 	util_debug(client->debug_callback, client->debug_data,
 			"Failed to initialize gatt-client");
 
+	op->success = false;
+
 done:
 	if (client->ready_callback)
 		client->ready_callback(success, att_ecode, client->ready_data);