From 0bfbda5996ca795c1b5d781c11be490035dc9c23 Mon Sep 17 00:00:00 2001 From: "Arnold D. Robbins" Date: Thu, 7 Jan 2021 22:16:35 +0200 Subject: Bug fix when RS matches null string. --- io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'io.c') diff --git a/io.c b/io.c index 2714398e..0af8ab1e 100644 --- a/io.c +++ b/io.c @@ -3702,7 +3702,7 @@ again: * If still room in buffer, skip over null match * and restart search. Otherwise, return. */ - if (bp + iop->scanoff < iop->dataend) { + if (bp + iop->scanoff <= iop->dataend) { bp += iop->scanoff; goto again; } -- cgit v1.2.1