X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;ds=inline;f=findutils%2Fgrep.c;h=c4cfcb8527abbf14e597deaddb990fcc7d92a1cb;hb=68404f13d4bf4826e3609703dad5375763db28ab;hp=c2a6a2187df93e3848c909dbc624d6a3bdfa38c7;hpb=681023650e69f6e4fa959c5c6f0480d4a0edf906;p=oweals%2Fbusybox.git diff --git a/findutils/grep.c b/findutils/grep.c index c2a6a2187..c4cfcb852 100644 --- a/findutils/grep.c +++ b/findutils/grep.c @@ -229,7 +229,7 @@ static int grep_file(FILE *file) /* if we're just printing filenames, we stop after the first match */ if (PRINT_FILES_WITH_MATCHES) { puts(cur_file); - /* fall thru to "return 1" */ + /* fall through to "return 1" */ } /* OPT_L aka PRINT_FILES_WITHOUT_MATCHES: return early */ return 1; /* one match */ @@ -371,12 +371,12 @@ static void load_regexes_from_file(llist_t *fopt) } } -static int file_action_grep(const char *filename, struct stat *statbuf, void* matched, int depth) +static int file_action_grep(const char *filename, struct stat *statbuf ATTRIBUTE_UNUSED, void* matched, int depth ATTRIBUTE_UNUSED) { FILE *file = fopen(filename, "r"); if (file == NULL) { if (!SUPPRESS_ERR_MSGS) - bb_simple_perror_msg(cur_file); + bb_simple_perror_msg(filename); open_errors = 1; return 0; }