We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b9cb077 + 34f3999 commit 7d0dafeCopy full SHA for 7d0dafe
1 file changed
builtin-grep.c
@@ -205,6 +205,7 @@ static int grep_file(struct grep_opt *opt, const char *filename)
205
return 0;
206
}
207
close(i);
208
+ data[sz] = 0;
209
if (opt->relative && opt->prefix_length)
210
filename = quote_path_relative(filename, -1, &buf, opt->prefix);
211
i = grep_buffer(opt, filename, data, sz);
0 commit comments