>I'd switch to using a BinaryReader if it's not a text file. Not quite as easy to use, but not too bad either. Just create a small array as a buffer and run a loop to fill it/write it out until it's complete.
Well, I've used this approach so far for encoding a file to Base64 and things like that. The process is really simple. There is a file on disk. I want to get a hold of it, stream it into a StreamWriter and write it back on disk. This should give me the same amount of bytes and the same file after. That works at 99.99%. But, in a very rare case, it is not. Before rewriting everything, I would like to make sure there is really a problem that I cannot control. I am still looking at the code to see if I missed something.