summaryrefslogtreecommitdiff
path: root/doc/grep.texi
diff options
context:
space:
mode:
authorAlain Magloire <alainm@rcsm.ee.mcgill.ca>2001-07-29 19:32:15 +0000
committerAlain Magloire <alainm@rcsm.ee.mcgill.ca>2001-07-29 19:32:15 +0000
commit418c7f7900a794eb647c9cb69d496757f9723fca (patch)
treeaf99702b9c07bdb8e39b47d25dc81d0c5f40edad /doc/grep.texi
parentf81b20eb931851b5cac82cbf4fe7abea0a2c7ec1 (diff)
downloadgrep-418c7f7900a794eb647c9cb69d496757f9723fca.tar.gz
* grep/src/grep.c (usage): Typos corrected.
Patches from Santiago Vila. 2001-07-29 Alain Magloire David Clissold, wrote: a small bug in the GNU grep 2.4.2, which may have gone unnoticed because it only causes a failure if building on a system with large files enabled (e.g. an "off_t" is a "long long" rather than a "long"). savedir() takes on off_t argument, but in grepdir() the parameter is cast to an (unsigned). Well, if an off_t is larger than an int, the value gets truncated. This would not normally have an effect on a little-endian platform (unless the file is >2GB), but on a big-endian system it will always fail. The external effect is that "grep -r foo dir_name" fails with ENOMEM (from malloc() within savedir()). * grep/src/grep.c (grepdir): Remove the (unsigned) cast when calling savedir(). * grep/src/grep.c (usage): Typos corrected. Patches from Santiago Vila. David Clissold, wrote: a small bug in the GNU grep 2.4.2, which may have gone unnoticed because it only causes a failure if building on a system with large files enabled (e.g. an "off_t" is a "long long" rather than a "long"). savedir() takes on off_t argument, but in grepdir() the parameter is cast to an (unsigned). Well, if an off_t is larger than an int, the value gets truncated. This would not normally have an effect on a little-endian platform (unless the file is >2GB), but on a big-endian system it will always fail. The external effect is that "grep -r foo dir_name" fails with ENOMEM (from malloc() within savedir()). * grep/src/grep.c (grepdir): Remove the (unsigned) cast when calling savedir(). * grep/doc/grep.texi: In Bugs report use {n,m} for consistency. * grep/doc/grep.1: Likewised. Noted by Steven Lucy.
Diffstat (limited to 'doc/grep.texi')
-rw-r--r--doc/grep.texi2
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/grep.texi b/doc/grep.texi
index 66ea5394..ee803e01 100644
--- a/doc/grep.texi
+++ b/doc/grep.texi
@@ -1211,7 +1211,7 @@ g/re/p
Email bug reports to @email{bug-gnu-utils@@gnu.org}.
Be sure to include the word ``grep'' somewhere in the ``Subject:'' field.
-Large repetition counts in the @samp{@{m,n@}} construct may cause
+Large repetition counts in the @samp{@{n,m@}} construct may cause
@command{grep} to use lots of memory. In addition, certain other
obscure regular expressions require exponential time and
space, and may cause grep to run out of memory.