From: Luiz Augusto von Dentz Date: Wed, 14 Mar 2018 12:56:30 +0000 (+0200) Subject: shared/gatt-client: Omit valid errors for primary discovery X-Git-Tag: accepted/tizen/unified/20190522.085452~1^2~144 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cdf03960dbcdd6ed51cf50fc21643e44efc14334;p=platform%2Fupstream%2Fbluez.git shared/gatt-client: Omit valid errors for primary discovery BT_ATT_ERROR_ATTRIBUTE_NOT_FOUND shall not cause anything to be printed since it is a valid response and just mark the end of primary discovery. Change-Id: Ideebfd3b7646f5082f07edb0ae03c74272f23ec5 Signed-off-by: Amit Purwar --- diff --git a/src/shared/gatt-client.c b/src/shared/gatt-client.c index fe86689..353aaa1 100644 --- a/src/shared/gatt-client.c +++ b/src/shared/gatt-client.c @@ -1161,9 +1161,6 @@ static void discover_primary_cb(bool success, uint8_t att_ecode, discovery_req_clear(client); if (!success) { - util_debug(client->debug_callback, client->debug_data, - "Primary service discovery failed." - " ATT ECODE: 0x%02x", att_ecode); /* Reset error in case of not found */ switch (att_ecode) { case BT_ATT_ERROR_ATTRIBUTE_NOT_FOUND: @@ -1171,6 +1168,9 @@ static void discover_primary_cb(bool success, uint8_t att_ecode, att_ecode = 0; goto secondary; default: + util_debug(client->debug_callback, client->debug_data, + "Primary service discovery failed." + " ATT ECODE: 0x%02x", att_ecode); goto done; } }