Remove incorrect entries in pg_walsummary's getopt_long call.
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 30 Sep 2024 16:06:54 +0000 (12:06 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 30 Sep 2024 16:06:54 +0000 (12:06 -0400)
For some reason this listed "-f" and "-w" as valid switches, though
the code doesn't implement any such thing nor do the docs mention
them.  The effect of this was that if you tried to use one of these
switches, you'd get an unhelpful error message.

Yusuke Sugie

Discussion: https://postgr.es/m/68e72a2a70f4d84c1c7847b13bcdaef8@oss.nttdata.com

src/bin/pg_walsummary/pg_walsummary.c

index 93f6e6d408a80bc0c59048cf498fe4141cb6a564..f6a262d3184faa025bda4fcf9133f3e9200f84d2 100644 (file)
@@ -71,7 +71,7 @@ main(int argc, char *argv[])
        handle_help_version_opts(argc, argv, progname, help);
 
        /* process command-line options */
-       while ((c = getopt_long(argc, argv, "f:iqw:",
+       while ((c = getopt_long(argc, argv, "iq",
                                                        long_options, &optindex)) != -1)
        {
                switch (c)