header.version = htons(default_version);
header.options = htons(flags | options);
header.entry_count = htonl(writer.selected_nr);
- memcpy(header.checksum, writer.pack_checksum, 20);
+ hashcpy(header.checksum, writer.pack_checksum);
sha1write(f, &header, sizeof(header));
dump_bitmap(f, writer.commits);