fix prepared write offset

This commit is contained in:
matthias.ringwald@gmail.com 2014-01-30 11:39:19 +00:00
parent 90bf7361a7
commit 7799a836c1

View File

@ -855,7 +855,7 @@ static uint16_t handle_prepare_write_request(att_connection_t * att_connection,
return setup_error(response_buffer, ATT_PREPARE_WRITE_REQUEST, handle, error_code); return setup_error(response_buffer, ATT_PREPARE_WRITE_REQUEST, handle, error_code);
} }
int result = (*att_write_callback)(handle, ATT_TRANSACTION_MODE_ACTIVE, offset, request_buffer + 3, request_len - 3, NULL); int result = (*att_write_callback)(handle, ATT_TRANSACTION_MODE_ACTIVE, offset, request_buffer + 5, request_len - 5, NULL);
if (result){ if (result){
return setup_error(response_buffer, ATT_PREPARE_WRITE_REQUEST, handle, result); return setup_error(response_buffer, ATT_PREPARE_WRITE_REQUEST, handle, result);
} }