From 2d7cb07e3718d0af6547e2abb35f9cff9b10c1f5 Mon Sep 17 00:00:00 2001 From: Ramsay Jones Date: Fri, 2 Mar 2018 02:54:02 +0000 Subject: [PATCH] ref-filter: mark a file-local symbol as static Commit fcfba37337 ('ref-filter: make "--contains " less chatty if is invalid', 2018-02-23) added the add_str_to_commit_list() function, which causes sparse to issue a "... not declared. Should it be static?" warning for that symbol. Indeed, the function is only used in this one compilation unit. Mark it static. Signed-off-by: Ramsay Jones Signed-off-by: Junio C Hamano --- ref-filter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ref-filter.c b/ref-filter.c index aa282a27f4..ed993d32d8 100644 --- a/ref-filter.c +++ b/ref-filter.c @@ -2000,7 +2000,7 @@ static void do_merge_filter(struct ref_filter_cbdata *ref_cbdata) free(to_clear); } -int add_str_to_commit_list(struct string_list_item *item, void *commit_list) +static int add_str_to_commit_list(struct string_list_item *item, void *commit_list) { struct object_id oid; struct commit *commit; -- 2.49.0