InputFile.Open(FileName,CFile::modeRead|CFile::typeBinary))

Let's me read a lot further but it still exits way before the actual end of the file.