sha1_file.c: simplify parse_pack_index()