diff options
author | Robert Haas | 2012-09-06 19:43:46 +0000 |
---|---|---|
committer | Robert Haas | 2012-09-06 19:52:11 +0000 |
commit | 83f2584f15d9450834f3b3d5e4a2edaa7c00dc60 (patch) | |
tree | f726579a2db691daa1908035c7e396623b57d2e6 | |
parent | 987277f402a31ba91ea647d115785e5a4f7850fa (diff) |
Fix "too many arguments" messages not to index off the end of argv[].
This affects initdb, clusterdb, reindexdb, and vacuumdb in master
and 9.2; in earlier branches, only initdb is affected.
-rw-r--r-- | src/bin/initdb/initdb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bin/initdb/initdb.c b/src/bin/initdb/initdb.c index 7ca4c934318..d5101fad2fc 100644 --- a/src/bin/initdb/initdb.c +++ b/src/bin/initdb/initdb.c @@ -2573,7 +2573,7 @@ main(int argc, char *argv[]) if (optind < argc) { fprintf(stderr, _("%s: too many command-line arguments (first is \"%s\")\n"), - progname, argv[optind + 1]); + progname, argv[optind]); fprintf(stderr, _("Try \"%s --help\" for more information.\n"), progname); exit(1); |