Read generated files in binary mode

Resolves #51 by reading files in binary mode.