OSDN Git Service
(root)
/
android-x86
/
system-bt.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8605191
)
Decrease length after reading from array in process_service_attr_req
author
Jakub Pawlowski
<jpawlowski@google.com>
Tue, 29 May 2018 23:17:32 +0000
(16:17 -0700)
committer
Vasyl Gello
<vasek.gello@gmail.com>
Wed, 8 Aug 2018 06:06:13 +0000
(09:06 +0300)
Test: compilation
Bug:
78136677
Change-Id: I4807a350e2b4764a93f104ce88f23a957a7e85c0
(cherry picked from commit
6cd2e8bf6e5707e8e77e7aca6519c58200ee58db
)
stack/sdp/sdp_server.c
patch
|
blob
|
history
diff --git
a/stack/sdp/sdp_server.c
b/stack/sdp/sdp_server.c
index
dc5ecbd
..
4a0d4b5
100644
(file)
--- a/
stack/sdp/sdp_server.c
+++ b/
stack/sdp/sdp_server.c
@@
-622,9
+622,11
@@
static void process_service_attr_req (tCONN_CB *p_ccb, UINT16 trans_num,
/* Extract the record handle */
BE_STREAM_TO_UINT32(rec_handle, p_req);
+ param_len -= sizeof(rec_handle);
/* Get the max list length we can send. Cap it at MTU size minus overhead */
BE_STREAM_TO_UINT16 (max_list_len, p_req);
+ param_len -= sizeof(max_list_len);
if (max_list_len > (p_ccb->rem_mtu_size - SDP_MAX_ATTR_RSPHDR_LEN))
max_list_len = p_ccb->rem_mtu_size - SDP_MAX_ATTR_RSPHDR_LEN;