summaryrefslogtreecommitdiff
path: root/profiles
diff options
context:
space:
mode:
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2014-07-31 15:03:29 +0300
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2014-07-31 15:35:04 +0300
commit67ec26fa394c16c657b40cc0991ec8ac42f2e57b (patch)
treeb3423d03e92dd57b78111ff448478ee48504458a /profiles
parent3b8d6b19e647501133124c02350d85e5c29525cb (diff)
downloadbluez-67ec26fa394c16c657b40cc0991ec8ac42f2e57b.tar.gz
audio/avrcp: Fix not accounting all items when listing
The total number of items should account that the start and end index are included so end - start index is incorrect.
Diffstat (limited to 'profiles')
-rw-r--r--profiles/audio/avrcp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/profiles/audio/avrcp.c b/profiles/audio/avrcp.c
index da2a7464f..29edd3363 100644
--- a/profiles/audio/avrcp.c
+++ b/profiles/audio/avrcp.c
@@ -2250,7 +2250,7 @@ static gboolean avrcp_list_items_rsp(struct avctp *conn, uint8_t *operands,
}
items = g_slist_length(p->items);
- total = p->end - p->start;
+ total = p->end - p->start + 1;
if (items < total) {
avrcp_list_items(session, p->start + items + 1, p->end);
return FALSE;