Fixed bug in checksum.