Catch EOF error too