grep-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Grep-devel] grep-2.27 released [stable]


From: Paul Eggert
Subject: Re: [Grep-devel] grep-2.27 released [stable]
Date: Wed, 7 Dec 2016 12:22:31 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1

On 12/07/2016 09:26 AM, Dmitry V. Levin wrote:
it probably means that

        yes | grep --quiet . || echo yes or grep failed

will never terminate.

Actually, that terminates too, as grep 2.27 keeps reading only if you don't specify -q, -l, -L, -m0, -f /dev/null, etc. -- basically, any option that a naive and unportable script is so unlikely to use that it's OK to optimize. I installed the attached patch to NEWS to try to clarify this. The 2nd patch is a minor simplification of the relevant code.

Attachment: 0001-maint-clarify-early-exit-news-for-2.27.patch
Description: Source code patch

Attachment: 0002-grep-simplify-finalize_input.patch
Description: Source code patch


reply via email to

[Prev in Thread] Current Thread [Next in Thread]