Fix cf-upgrade's self-copy in windows.

Yep, ``st_size`` is particularly dangerous without ``O_BINARY``, because what you read will almost always be smaller than ``st_size``, unless the file has no newlines at all.