OSDN Git Service

Fix reliable write.
authorQiyu Hu <qiyuh@google.com>
Wed, 13 Jun 2018 15:08:17 +0000 (08:08 -0700)
committerAndre Eisenbach <eisenbach@google.com>
Tue, 14 Aug 2018 22:49:15 +0000 (22:49 +0000)
commit24f0bad86fd83c7ba80e1f14d65bd53fe614a4e5
treefb60666ff8f6886dec141bd2fc4984bd16a3e66e
parentdedbd07ba8b906a01721ec6d772a952955c4e2b1
Fix reliable write.

We cannot simply assume the write is terminated in reliable write. When
the reliable write value is longer than MTU allows, the current
implementation can only send whatever MTU allows and naively set the
status to GATT_SUCCESS, in the name of "application should verify handle
offset and value are matched or not". That's why MTU negotiation is a
workaround as people mention in b/37031096, which just fits all the write
value into a single request.

This also blocks our test on CtsVerifier.

Bug: 37031096
Test: Manual test and confirm that we don't simply send partial value
Change-Id: I907877608f4672f24c002e630e58bf9133937a5e
stack/gatt/gatt_cl.cc