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:
afe11be
)
Add missing extension length check while parsing BNEP control packets
author
Pavlin Radoslavov
<pavlin@google.com>
Mon, 17 Jul 2017 23:03:21 +0000
(16:03 -0700)
committer
Pavlin Radoslavov
<pavlin@google.com>
Tue, 18 Jul 2017 01:06:23 +0000
(18:06 -0700)
Bug:
63146237
Test: External script
Change-Id: I4e519cec1c7dffb8bd42add00bd891e0969a3d9f
(cherry picked from commit
9ab89b7dbe5735b796799f65144efa48595d0230
)
stack/bnep/bnep_utils.cc
patch
|
blob
|
history
diff --git
a/stack/bnep/bnep_utils.cc
b/stack/bnep/bnep_utils.cc
index
3f5e13e
..
ed4d712
100644
(file)
--- a/
stack/bnep/bnep_utils.cc
+++ b/
stack/bnep/bnep_utils.cc
@@
-832,7
+832,7
@@
uint8_t* bnep_process_control_packet(tBNEP_CONN* p_bcb, uint8_t* p,
BNEP_TRACE_ERROR("%s: BNEP - bad ctl pkt type: %d", __func__,
control_type);
bnep_send_command_not_understood(p_bcb, control_type);
- if (is_ext) {
+ if (is_ext
&& (ext_len > 0)
) {
if (*rem_len < (ext_len - 1)) {
goto bad_packet_length;
}