Skip to content

Commit b8db6ed

Browse files
avargitster
authored andcommitted
grep.c: don't pass along NULL callback value
Change grep_cmd_config() to stop passing around the always-NULL "cb" value. When this code was added in 7e8f59d (grep: color patterns in output, 2009-03-07) it was non-NULL, but when that changed in 15fabd1 (builtin/grep.c: make configuration callback more reusable, 2012-10-09) this code was left behind. In a subsequent change I'll start using the "cb" value, this will make it clear which functions we call need it, and which don't. Signed-off-by: Ævar Arnfjörð Bjarmason <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 9725c8d commit b8db6ed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

builtin/grep.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -285,8 +285,8 @@ static int wait_all(void)
285285

286286
static int grep_cmd_config(const char *var, const char *value, void *cb)
287287
{
288-
int st = grep_config(var, value, cb);
289-
if (git_color_default_config(var, value, cb) < 0)
288+
int st = grep_config(var, value, NULL);
289+
if (git_color_default_config(var, value, NULL) < 0)
290290
st = -1;
291291

292292
if (!strcmp(var, "grep.threads")) {

0 commit comments

Comments
 (0)