adding message length in the packet