Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCHv2 1/2] android/gatt: Fix not checking for read errors in read by type
@ 2014-05-28  9:17 Jakub Tyszkowski
  2014-05-28  9:18 ` [PATCHv2 2/2] android/pts: Update GATT PTS results Jakub Tyszkowski
  2014-05-28  9:27 ` [PATCHv2 1/2] android/gatt: Fix not checking for read errors in read by type Szymon Janc
  0 siblings, 2 replies; 3+ messages in thread
From: Jakub Tyszkowski @ 2014-05-28  9:17 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Jakub Tyszkowski

---
 android/gatt.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/android/gatt.c b/android/gatt.c
index 9234b46..6189407 100644
--- a/android/gatt.c
+++ b/android/gatt.c
@@ -3643,9 +3643,15 @@ static void send_dev_pending_response(struct gatt_device *device,
 			goto done;
 		}
 
+		if (val->error) {
+			queue_destroy(temp, NULL);
+			error = val->error;
+			goto done;
+		}
+
 		length = val->length;
 
-		while (val && val->length == length) {
+		while (val && val->length == length && val->error == 0) {
 			queue_push_tail(temp, val);
 			val = queue_pop_head(device->pending_requests);
 		}
-- 
1.9.3


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-05-28  9:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-28  9:17 [PATCHv2 1/2] android/gatt: Fix not checking for read errors in read by type Jakub Tyszkowski
2014-05-28  9:18 ` [PATCHv2 2/2] android/pts: Update GATT PTS results Jakub Tyszkowski
2014-05-28  9:27 ` [PATCHv2 1/2] android/gatt: Fix not checking for read errors in read by type Szymon Janc

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox