Skip to content

Commit 019a32c

Browse files
no need to check again
1 parent f876179 commit 019a32c

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

connectivity/FEATURE_BLE/libraries/ble-api-implementation/source/GattServerImpl.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -994,9 +994,7 @@ uint8_t GattServer::atts_write_cb(
994994
/* we don't write anything during the prepare phase */
995995
bool write_happened = (operation != ATT_PDU_PREP_WRITE_REQ);
996996

997-
if (len > pAttr->maxLen) {
998-
return ATT_ERR_LENGTH;
999-
}
997+
MBED_ASSERT(len + offset <= pAttr->maxLen);
1000998

1001999
if (write_happened) {
10021000
WsfTaskLock();

0 commit comments

Comments
 (0)