grep-commit
[Top][All Lists]
Advanced

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

grep branch, master, updated. v2.22-13-g1c6e372


From: Paul Eggert
Subject: grep branch, master, updated. v2.22-13-g1c6e372
Date: Thu, 31 Dec 2015 18:02:56 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "grep".

The branch, master has been updated
       via  1c6e37246cbc1bba8624b43ddd5e08275923034e (commit)
      from  d719afe5a025a7be3c60b0efcf0656f93a6716b6 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/grep.git/commit/?id=1c6e37246cbc1bba8624b43ddd5e08275923034e


commit 1c6e37246cbc1bba8624b43ddd5e08275923034e
Author: Paul Eggert <address@hidden>
Date:   Thu Dec 31 10:02:31 2015 -0800

    doc: clarify text vs binary match output
    
    * NEWS:
    * doc/grep.texi (File and Directory Selection):
    Make it clearer that grep can now output matching text before
    reporting a binary match.  Problem reported by Norihiro Tanaka in:
    http://bugs.gnu.org/20526#83

diff --git a/NEWS b/NEWS
index b451d76..6e97e45 100644
--- a/NEWS
+++ b/NEWS
@@ -4,11 +4,15 @@ GNU grep NEWS                                    -*- outline 
-*-
 
 ** Bug fixes
 
-  Binary files are now less likely to generate diagnostics.  grep now
-  reports "Binary file FOO matches" and suppresses further output when
-  grep is about to output a match that contains an encoding error.
-  Formerly, grep reported FOO to be binary merely because grep found
-  an encoding error in FOO before generating output for FOO.
+  Binary files are now less likely to generate diagnostics and more
+  likely to yield text matches.  grep now reports "Binary file FOO
+  matches" and suppresses further output instead of outputting a line
+  containing a encoding error; hence grep can now report matching text
+  before a later binary match.  Formerly, grep reported FOO to be
+  binary when it found an encoding error in FOO before generating
+  output for FOO, which meant it never reported both matching text and
+  matching binary data; this was less useful for searching text
+  containing encoding errors in non-matching lines.
   [bug introduced in grep-2.21]
 
   grep -c no longer stops counting when finding binary data.
diff --git a/doc/grep.texi b/doc/grep.texi
index 73151e4..b9a4d25 100644
--- a/doc/grep.texi
+++ b/doc/grep.texi
@@ -594,8 +594,7 @@ this is equivalent to the @samp{--binary-files=text} option.
 @item address@hidden
 @opindex --binary-files
 @cindex binary files
-If a file's allocation metadata,
-or if its data read before a line is selected for output,
+If a file's data or metadata
 indicate that the file contains binary data,
 assume that the file is of type @var{type}.
 Non-text bytes indicate binary data; these are either output bytes that are
@@ -604,9 +603,9 @@ improperly encoded for the current locale, or null input 
bytes when the
 Options}).
 
 By default, @var{type} is @samp{binary}, and when @command{grep}
-discovers that a file is binary it normally outputs either
-a one-line message saying that a binary file matches,
-or no message if there is no match.
+discovers that a file is binary it suppresses any further output, and
+instead outputs either a one-line message saying that a binary file
+matches, or no message if there is no match.
 When processing binary data, @command{grep} may treat non-text bytes
 as line terminators; for example, the pattern @samp{.} (period) might
 not match a null byte, as the null byte might be treated as a line

-----------------------------------------------------------------------

Summary of changes:
 NEWS          |   14 +++++++++-----
 doc/grep.texi |    9 ++++-----
 2 files changed, 13 insertions(+), 10 deletions(-)


hooks/post-receive
-- 
grep



reply via email to

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