diff options
author | Junio C Hamano <gitster@pobox.com> | 2020-11-26 02:24:52 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-11-26 02:24:52 +0300 |
commit | 455e8d18f81583d0270685edc6ec2ed201fc984c (patch) | |
tree | cc8a2951eb2473f5970c505d03b1ef5349067d1a /pack-write.c | |
parent | 2557c1183a6c6025bc0dd6ebd84354064bb398ec (diff) | |
parent | 970909c2a7803564f82ab1d3660d77ad6a44b68f (diff) |
Merge branch 'rs/hashwrite-be64'
Code simplification.
* rs/hashwrite-be64:
pack-write: use hashwrite_be64()
midx: use hashwrite_be64()
csum-file: add hashwrite_be64()
Diffstat (limited to 'pack-write.c')
-rw-r--r-- | pack-write.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/pack-write.c b/pack-write.c index 23e19cc1ec..3513665e1e 100644 --- a/pack-write.c +++ b/pack-write.c @@ -151,13 +151,10 @@ const char *write_idx_file(const char *index_name, struct pack_idx_entry **objec while (nr_large_offset) { struct pack_idx_entry *obj = *list++; uint64_t offset = obj->offset; - uint32_t split[2]; if (!need_large_offset(offset, opts)) continue; - split[0] = htonl(offset >> 32); - split[1] = htonl(offset & 0xffffffff); - hashwrite(f, split, 8); + hashwrite_be64(f, offset); nr_large_offset--; } } |