fixed minor client read_file bugs