fix message checksum calculation bug