Clean up error checking in get_file_buffer().

Bit silly to not check the precise error codes.