summaryrefslogtreecommitdiff
path: root/commit.c
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2020-12-11 09:08:42 +0000
committerJunio C Hamano <gitster@pobox.com>2020-12-14 09:34:50 -0800
commitad8a1be529ea9e0bd6346a3cb1d53fec16e3bd10 (patch)
tree06291a5270d788d5d80b6939ad932cb5e35d7ea3 /commit.c
parent00b8cccdd83c6f8c9ffefd133b291dadf8e788d7 (diff)
diffcore-rename: simplify limit check
diffcore-rename had two different checks of the form if ((a < limit || b < limit) && a * b <= limit * limit) This can be simplified to if (st_mult(a, b) <= st_mult(limit, limit)) which makes it clearer how we are checking for overflow, and makes it much easier to parse given the drop from 8 to 4 variable appearances. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit.c')
0 files changed, 0 insertions, 0 deletions