You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* tests: use a explicit filehandle to share in testing -m
The way stdin is shared to all participants of a subshell varies
per shell, and at least the standard /bin/sh in Solaris seem to
create a new copy for each command, defeating the purpose of the
test.
Use instead exec to create a filehandle that could then be used
explicitly in the test to confirm that the stream is set.
* pcre2grep: correctly handle multiple passes
When the -m option is used, pcre2grep is meant to exit after enough
matches are found but while leaving the stream pinned to the next position
after the last match.
Unfortunately, it wasn't tracking correctly the beginning of the stream
on subsequent passes, and therefore it will fail to use the right seek
value.
Grab the position of the stream at the beginning and while at it, make
sure that the stream passed hasn't been consumed already.
0 commit comments