C# Binary File Compare

Posted by Simon Farrow on Stack Overflow See other posts from Stack Overflow or by Simon Farrow
Published on 2009-06-09T08:50:40Z Indexed on 2010/04/14 12:33 UTC
Read the original article Hit count: 391

Filed under:
|
|

I'm in a situation where I want to compare two binary files. One of them is already stored on the server with a pre-calculated Crc32 in the database from when I stored it originally.

I know that if the Crc is different then the files are definitely different. However, if the Crc is the same I don't know that the files are. So what I'm looking for is a nice efficient way of comparing the two streams on from the posted file and one from the file system.

I'm not an expert on streams but I'm well aware that I could easily shoot myself in the foot here as far as memory usage is concerned.

Any help is greatly appreciated.

© Stack Overflow or respective owner

Related posts about files

Related posts about compare