Fix bug, data_len wasn't sending

Fixed bug, data len wasn’t sending in the earlier implementation. Fixed
it.