From: Ralph Smith Date: 2005-10-25T17:37:02+09:00 Subject: ruby gives different answer for checksum of files on windows and FreeBSD? If I run this code to compute a "checksum" of a file I get a different answer on a windows machine and a FreeBSD machine. Does anyone know why? Or a better way to get a quick checksum of a file? fname = ARGV[0] size = File.size(fname); checksum = 0; f = File.new(fname) f.each_byte {|x| checksum += x } printf("%s: %d ( %x hex )\n", fname, checksum, checksum) Thanks, Ralph