]> granicus.if.org Git - graphviz/commitdiff
Fix cluster -? to actually print usage instead of error on macOS
authorMagnus Jacobsson <Magnus.Jacobsson@berotec.se>
Tue, 20 Oct 2020 06:29:03 +0000 (08:29 +0200)
committerMagnus Jacobsson <magnus.jacobsson@berotec.se>
Sat, 24 Oct 2020 05:46:24 +0000 (07:46 +0200)
Towards https://gitlab.com/graphviz/graphviz/-/issues/1852.

cmd/gvmap/cluster.c

index e5232bac96a042ac4ea2a4f56ab7889231cf4b87..a7fcdf7c98a64c17c81aa0a259c91d2eb67e6ca3 100644 (file)
@@ -120,7 +120,7 @@ static void init(int argc, char *argv[], opts_t* opts) {
       Verbose = 1;
       break;
     case '?':
-      if (optopt == '\0')
+      if (optopt == '\0' || optopt == '?')
        usage(cmd, 0);
       else {
        fprintf(stderr, " option -%c unrecognized\n",