summaryrefslogtreecommitdiffstats
path: root/builtin/grep.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2017-07-13 00:18:23 +0200
committerJunio C Hamano <gitster@pobox.com>2017-07-13 00:18:23 +0200
commitf056cde60e7b095edf1530554a8c9528bd8b374b (patch)
tree1507f5729cc2a2718b59712b0aac3a7350c2144f /builtin/grep.c
parentMerge branch 'kn/ref-filter-branch-list' (diff)
parentuse DIV_ROUND_UP (diff)
downloadgit-f056cde60e7b095edf1530554a8c9528bd8b374b.tar.xz
git-f056cde60e7b095edf1530554a8c9528bd8b374b.zip
Merge branch 'rs/use-div-round-up'
Code cleanup. * rs/use-div-round-up: use DIV_ROUND_UP
Diffstat (limited to 'builtin/grep.c')
-rw-r--r--builtin/grep.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/grep.c b/builtin/grep.c
index fa351c49f4..0d6e669732 100644
--- a/builtin/grep.c
+++ b/builtin/grep.c
@@ -543,7 +543,7 @@ static void compile_submodule_options(const struct grep_opt *opt,
* submodule process has its own thread pool.
*/
argv_array_pushf(&submodule_options, "--threads=%d",
- (num_threads + 1) / 2);
+ DIV_ROUND_UP(num_threads, 2));
/* Add Pathspecs */
argv_array_push(&submodule_options, "--");