Merge branch 'fixes-from-the-git-mailing-list'

These fixes have been sent to the Git mailing list but have not been
picked up by the Git project yet.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
Johannes Schindelin 2025-01-22 11:23:06 +01:00
commit afb14d1c55

2
grep.c
View File

@ -1646,6 +1646,8 @@ static int grep_source_1(struct grep_opt *opt, struct grep_source *gs, int colle
bol = gs->buf;
left = gs->size;
if (left && gs->buf[left-1] == '\n')
left--;
while (left) {
const char *eol;
int hit;