summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2012-04-27 11:42:23 +0200
committerJim Meyering <meyering@redhat.com>2012-04-30 09:49:21 +0200
commitc6254ca5fb9b3b513e54bd2a8de94c34af39fbc6 (patch)
tree40282e8ac5c39f337c5b5b845ceeac0e4061788c
parent69d06a2c3c7cdcd296da4fe92d7ed7256c4d0395 (diff)
downloadgrep-c6254ca5fb9b3b513e54bd2a8de94c34af39fbc6.tar.gz
grep: -K is not an option: remove it from list
The presence of "K" in the short-option string meant that an erroneous "grep -K ..." would fail with a bare Usage/Try... message, without the usual "invalid option -- 'K'". With this removal, now grep prints the expected invalid option diagnostic. * src/main.c (short_options): Remove "K". Reported by Петр Досычев in http://thread.gmane.org/gmane.comp.gnu.grep.bugs/4488
-rw-r--r--src/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index c5a84898..cb6da2ca 100644
--- a/src/main.c
+++ b/src/main.c
@@ -276,7 +276,7 @@ static struct exclude *included_patterns;
static struct exclude *excluded_directory_patterns;
/* Short options. */
static char const short_options[] =
-"0123456789A:B:C:D:EFGHIPTUVX:abcd:e:f:hiKLlm:noqRrsuvwxyZz";
+"0123456789A:B:C:D:EFGHIPTUVX:abcd:e:f:hiLlm:noqRrsuvwxyZz";
/* Non-boolean long options that have no corresponding short equivalents. */
enum