Fixed type error when trying to read a file with no specified size