diff options
author | Miriam Rubio <mirucam@gmail.com> | 2020-08-28 15:46:06 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-08-29 02:21:16 +0300 |
commit | 30276765c114bbd57ef0d8e6cf5489501599421a (patch) | |
tree | 622eaf90a535d14841142cb624b0bb026ee9b1a3 /builtin/bisect--helper.c | |
parent | ef5aef5ee0f8ff932f8beb21ff33a4dafee214b5 (diff) |
bisect--helper: use '-res' in 'cmd_bisect__helper' return
Following 'enum bisect_error' vocabulary, return variable 'res' is
always non-positive.
Let's use '-res' instead of 'abs(res)' to make the code clearer.
Mentored-by: Christian Couder <chriscool@tuxfamily.org>
Helped-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Miriam Rubio <mirucam@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/bisect--helper.c')
-rw-r--r-- | builtin/bisect--helper.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/bisect--helper.c b/builtin/bisect--helper.c index f464e957923..b7345be3a58 100644 --- a/builtin/bisect--helper.c +++ b/builtin/bisect--helper.c @@ -731,5 +731,5 @@ int cmd_bisect__helper(int argc, const char **argv, const char *prefix) if (res == BISECT_INTERNAL_SUCCESS_MERGE_BASE) res = BISECT_OK; - return abs(res); + return -res; } |