aboutsummaryrefslogtreecommitdiffstats
path: root/awklib/eg/prog/uniq.awk
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2014-09-10 08:18:21 +0300
committerArnold D. Robbins <arnold@skeeve.com>2014-09-10 08:18:21 +0300
commit6de0102373304c0fdf70a7ddeb17dd1caa3a9b23 (patch)
tree7a8f3f18180e0b84893a4cccd883c80ffb7d9bc0 /awklib/eg/prog/uniq.awk
parentd7c8dfd41bd5671ddfa6c81b2ef1779cab06e56b (diff)
parentca9f23d6c33c4b5cb3786d480948a42988ca99ac (diff)
downloadegawk-6de0102373304c0fdf70a7ddeb17dd1caa3a9b23.tar.gz
egawk-6de0102373304c0fdf70a7ddeb17dd1caa3a9b23.tar.bz2
egawk-6de0102373304c0fdf70a7ddeb17dd1caa3a9b23.zip
Merge branch 'master' into comment
Diffstat (limited to 'awklib/eg/prog/uniq.awk')
-rw-r--r--awklib/eg/prog/uniq.awk5
1 files changed, 2 insertions, 3 deletions
diff --git a/awklib/eg/prog/uniq.awk b/awklib/eg/prog/uniq.awk
index 990387ac..2a2cf63e 100644
--- a/awklib/eg/prog/uniq.awk
+++ b/awklib/eg/prog/uniq.awk
@@ -18,8 +18,7 @@ function usage( e)
# -n skip n fields
# +n skip n characters, skip fields first
-BEGIN \
-{
+BEGIN {
count = 1
outputfile = "/dev/stdout"
opts = "udc0:1:2:3:4:5:6:7:8:9:"
@@ -31,7 +30,7 @@ BEGIN \
else if (c == "c")
do_count++
else if (index("0123456789", c) != 0) {
- # getopt requires args to options
+ # getopt() requires args to options
# this messes us up for things like -5
if (Optarg ~ /^[[:digit:]]+$/)
fcount = (c Optarg) + 0