diff options
Diffstat (limited to 'sha1_name.c')
-rw-r--r-- | sha1_name.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sha1_name.c b/sha1_name.c index 134ac9742f..c7c5ab376c 100644 --- a/sha1_name.c +++ b/sha1_name.c @@ -157,7 +157,7 @@ static void unique_in_pack(struct packed_git *p, num = p->num_objects; last = num; while (first < last) { - uint32_t mid = (first + last) / 2; + uint32_t mid = first + (last - first) / 2; const unsigned char *current; int cmp; |