// VerifyChecksum validates the checksum for the data against the given expected checksum.
VerifyChecksum validates the checksum for the data against the given expected checksum.
// VerifyChecksum validates the checksum for the data against the given expected checksum .
func VerifyChecksum(data []byte, expected *pb.Checksum) error {
	actual := CalculateChecksum(data, expected.Algo)
	if actual != expected.Sum {
		return Wrapf(ErrChecksumMismatch, "actual: %d, expected: %d", actual, expected.Sum)
	}
	return nil
}
func VerifyChecksum ( data [ ] byte , expected * pb . Checksum ) error { actual := CalculateChecksum ( data , expected . Algo ) if actual != expected . Sum { return Wrapf ( ErrChecksumMismatch , " " , actual , expected . Sum ) } return nil }
VerifyChecksum validates the checksum for the data against the given expected checksum.
VerifyChecksum validates the checksum for the data against the given expected checksum .