Changed exit status of each nmh command's -version and -help switches
authorDavid Levine <levinedl@acm.org>
Thu, 7 Jun 2012 02:08:53 +0000 (21:08 -0500)
committerDavid Levine <levinedl@acm.org>
Thu, 7 Jun 2012 02:08:53 +0000 (21:08 -0500)
from 1 to 0.

52 files changed:
docs/pending-release-notes
test/mhparam/test-mhparam
test/mhpath/test-mhpath
uip/ali.c
uip/anno.c
uip/ap.c
uip/burst.c
uip/comp.c
uip/conflict.c
uip/dist.c
uip/dp.c
uip/flist.c
uip/fmtdump.c
uip/folder.c
uip/forw.c
uip/inc.c
uip/install-mh.c
uip/mark.c
uip/mhbuild.c
uip/mhlist.c
uip/mhlsbr.c
uip/mhmail.c
uip/mhn.c
uip/mhparam.c
uip/mhpath.c
uip/mhshow.c
uip/mhstore.c
uip/mhtest.c
uip/msgchk.c
uip/msh.c
uip/new.c
uip/packf.c
uip/pick.c
uip/post.c
uip/prompter.c
uip/rcvdist.c
uip/rcvpack.c
uip/rcvstore.c
uip/rcvtty.c
uip/refile.c
uip/repl.c
uip/rmf.c
uip/rmm.c
uip/scan.c
uip/send.c
uip/show.c
uip/slocal.c
uip/sortm.c
uip/spost.c
uip/viamail.c
uip/whatnowsbr.c
uip/whom.c

index 226d1fb..825f992 100644 (file)
@@ -1,2 +1,6 @@
 Things to add to the release notes for the next full release:
 
+Backward incompatibilities:
+-- Changed exit status of each nmh command's -version and -help
+   switches from 1 to 0.
+
index 573020e..bdab715 100755 (executable)
@@ -31,20 +31,17 @@ Usage: mhparam [profile-components] [switches]
   -version
   -help
 EOF
-# The exit status is 1 with -help, so temporarily disable -e.
-set +e
+
+# check -help
 mhparam -help >$actual 2>&1
-set -e
 check $expected $actual
 
-# check -version, which returns non-zero exit status
-set +e
+# check -version
 case `mhparam -v` in
   mhparam\ --*) ;;
   *           ) echo "$0: mhparam -v generated unexpected output" 1>&2
                 failed=`expr ${failed:-0} + 1`;;
 esac
-set -e
 
 # check unknown option
 run_test 'mhparam -nonexistent' 'mhparam: -nonexistent unknown'
index 84f14e2..9bb1207 100755 (executable)
@@ -27,20 +27,17 @@ Usage: mhpath [+folder] [msgs] [switches]
   -version
   -help
 EOF
-# The exit status is 1 with -help, so temporarily disable -e.
-set +e
+
+# check -help
 mhpath -help > $actual 2>&1
-set -e
 check $expected $actual
 
-# check -version, which returns non-zero exit status
-set +e
+# check -version
 case `mhpath -v` in
   mhpath\ --*) ;;
   *          ) echo "$0: mhpath -v generated unexpected output" 1>&2
                failed=`expr ${failed:-0} + 1`;;
 esac
-set -e
 
 # check +
 run_test "mhpath +" "$MH_TEST_DIR/Mail"
index 41f92a6..61ab6b2 100644 (file)
--- a/uip/ali.c
+++ b/uip/ali.c
@@ -87,10 +87,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [switches] aliases ...",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version (invo_name);
-                   done (1);
+                   done (0);
 
                case ALIASW: 
                    if (!(cp = *argp++) || *cp == '-')
index ab15a4a..24726d7 100644 (file)
@@ -128,10 +128,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case COMPSW:
                    if (comp)
index b0934fb..b5b0c5b 100644 (file)
--- a/uip/ap.c
+++ b/uip/ap.c
@@ -82,10 +82,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [switches] addrs ...",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version (invo_name);
-                   done (1);
+                   done (0);
 
                case FORMSW: 
                    if (!(form = *argp++) || *form == '-')
index 980972e..6316e13 100644 (file)
@@ -86,10 +86,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case INPLSW: 
                inplace++;
index 7c72c7c..29ca1b7 100644 (file)
@@ -119,10 +119,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msg] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case EDITRSW: 
                    if (!(ed = *argp++) || *ed == '-')
index a3bd1d7..2324c65 100644 (file)
@@ -92,10 +92,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [switches] [aliasfiles ...]",
                        invo_name);
                    print_help (buf, switches, 0);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case MAILSW: 
                    if (!(cp = *argp++) || *cp == '-')
index 39fb07b..40732dc 100644 (file)
@@ -122,10 +122,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msg] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case ANNOSW: 
                    anot++;
index 4e9c5cb..a66beed 100644 (file)
--- a/uip/dp.c
+++ b/uip/dp.c
@@ -74,10 +74,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [switches] dates ...",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case FORMSW: 
                    if (!(form = *argp++) || *form == '-')
index 8d8b92e..b4aff9c 100644 (file)
@@ -165,10 +165,10 @@ main(int argc, char **argv)
                snprintf(buf, sizeof(buf), "%s [+folder1 [+folder2 ...]][switches]",
                        invo_name);
                print_help(buf, switches, 1);
-               done(1);
+               done(0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case SEQSW:
                if (!(cp = *argp++) || *cp == '-')
index 26a6e58..0b3283d 100644 (file)
@@ -72,10 +72,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches]", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case FORMSW: 
                    if (!(form = *argp++) || *form == '-')
index 0676bea..aea20f4 100644 (file)
@@ -151,10 +151,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msg] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case ALLSW: 
                    all = 1;
index cd51fd1..a04ebd6 100644 (file)
@@ -167,10 +167,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case ANNOSW: 
                    anot++;
index edb288f..15aef0e 100644 (file)
--- a/uip/inc.c
+++ b/uip/inc.c
@@ -260,10 +260,10 @@ main (int argc, char **argv)
            case HELPSW: 
                snprintf (buf, sizeof(buf), "%s [+folder] [switches]", invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case AUDSW: 
                if (!(cp = *argp++) || *cp == '-')
index c484771..2cf9081 100644 (file)
@@ -61,10 +61,10 @@ main (int argc, char **argv)
                case HELPSW:
                    snprintf (buf, sizeof(buf), "%s [switches]", invo_name);
                    print_help (buf, switches, 0);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case AUTOSW:
                    autof++;
index 6ffc2b1..22a12ee 100644 (file)
@@ -84,10 +84,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                          invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case ADDSW: 
                addsw++;
index 020512d..c612fc5 100644 (file)
@@ -157,10 +157,10 @@ main (int argc, char **argv)
            case HELPSW: 
                snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case RCACHESW:
                icachesw = &rcachesw;
index 312705a..72b91d1 100644 (file)
@@ -151,10 +151,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case RCACHESW:
                icachesw = &rcachesw;
index df0a223..36e78d3 100644 (file)
@@ -370,10 +370,10 @@ mhl (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches] [files ...]", invo_name);
                    print_help (buf, mhlswitches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case BELLSW: 
                    bellflg = 1;
index f5e5384..76e9e80 100644 (file)
@@ -84,10 +84,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [addrs ... [switches]]",
                        invo_name);
                    print_help (buf, switches, 0);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case FROMSW: 
                    if (!(from = *argp++) || *from == '-')
index 3d8801e..d8826a1 100644 (file)
--- a/uip/mhn.c
+++ b/uip/mhn.c
@@ -240,10 +240,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case AUTOSW:
                autosw++;
index 90d17fa..9e6e05c 100644 (file)
@@ -107,10 +107,10 @@ main(int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [profile-components] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case COMPSW:
                    components = 1;
index 23ca542..bb77996 100644 (file)
@@ -55,10 +55,10 @@ main(int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
            }
        }
        if (*cp == '+' || *cp == '@') {
index 0d396b4..3db6abd 100644 (file)
@@ -167,10 +167,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case RCACHESW:
                icachesw = &rcachesw;
index 7814dd2..41e62c7 100644 (file)
@@ -145,10 +145,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case AUTOSW:
                autosw++;
index e5c4545..caaf7af 100644 (file)
@@ -147,10 +147,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case RCACHESW:
                icachesw = &rcachesw;
index 4cfb598..43ca792 100644 (file)
@@ -122,10 +122,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [switches] [users ...]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case DATESW:
                    datesw++;
index 03584f6..b3aa3a1 100644 (file)
--- a/uip/msh.c
+++ b/uip/msh.c
@@ -235,10 +235,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case IDSW: 
                    if (!(cp = *argp++) || *cp == '-')
index 38c8f0b..10854dc 100644 (file)
--- a/uip/new.c
+++ b/uip/new.c
@@ -438,10 +438,10 @@ main(int argc, char **argv)
                snprintf (help, sizeof(help), "%s [switches] [sequences]",
                          invo_name);
                print_help (help, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case FOLDERSSW:
                if (!(folders = *argp++) || *folders == '-')
index c365440..cd003dd 100644 (file)
@@ -75,10 +75,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case FILESW: 
                    if (file)
index bd17c45..fb63111 100644 (file)
@@ -113,11 +113,11 @@ main (int argc, char **argv)
                          invo_name);
                print_help (buf, switches, 1);
                listsw = 0;     /* HACK */
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
                listsw = 0;     /* HACK */
-               done (1);
+               done (0);
 
            case CCSW: 
            case DATESW: 
index c9b4c05..1116299 100644 (file)
@@ -343,10 +343,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
                    print_help (buf, switches, 0);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case LIBSW:
                    if (!(cp = *argp++) || *cp == '-')
index 981e820..795e472 100644 (file)
@@ -109,10 +109,10 @@ main (int argc, char **argv)
                    snprintf (buffer, sizeof(buffer), "%s [switches] file",
                        invo_name);
                    print_help (buffer, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case ERASESW: 
                    if (!(erasep = *argp++) || *erasep == '-')
index edbf65f..8ff0365 100644 (file)
@@ -74,10 +74,10 @@ main (int argc, char **argv)
                        "%s [switches] [switches for postproc] address ...",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case FORMSW: 
                    if (!(form = *argp++) || *form == '-')
index 0b4dc9f..f9e5bbb 100644 (file)
@@ -63,10 +63,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case MBOXSW:
                    mbx_style = MBOX_FORMAT;
index 57091b4..acf54be 100644 (file)
@@ -88,10 +88,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [switches]",
                          invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case SEQSW: 
                if (!(cp = *argp++) || *cp == '-')
index 63a97b9..29f2dd9 100644 (file)
@@ -109,10 +109,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [command ...]", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case BIFFSW:
                    biff = 1;
index 25f7629..2bd12ed 100644 (file)
@@ -100,10 +100,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [msgs] [switches] +folder ...",
                          invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case LINKSW: 
                linkf++;
index 07f25a8..c387da7 100644 (file)
@@ -181,7 +181,7 @@ main (int argc, char **argv)
                    done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case GROUPSW:
                    groupreply++;
index 5631f78..c9a04f5 100644 (file)
--- a/uip/rmf.c
+++ b/uip/rmf.c
@@ -59,10 +59,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case INTRSW: 
                    interactive = 1;
index 7680008..28c26fb 100644 (file)
--- a/uip/rmm.c
+++ b/uip/rmm.c
@@ -58,10 +58,10 @@ main (int argc, char **argv)
                snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                          invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case UNLINKSW:
                unlink_msgs++;
index 077f824..f49aa60 100644 (file)
@@ -99,10 +99,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case CLRSW: 
                    clearflag++;
index 577abac..6d075c1 100755 (executable)
@@ -198,10 +198,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [file] [switches]", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case DRAFTSW: 
                    msgs[msgp++] = draft;
index 8e581e7..ad9b123 100644 (file)
@@ -105,10 +105,10 @@ main (int argc, char **argv)
                        "%s [+folder] %s[switches] [switches for showproc]",
                        invo_name, mode == SHOW ? "[msgs] ": "");
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case DRFTSW: 
                    if (file)
index cc3c872..80620a7 100644 (file)
@@ -225,10 +225,10 @@ main (int argc, char **argv)
                    snprintf (buf, sizeof(buf),
                        "%s [switches] [address info sender]", invo_name);
                    print_help (buf, switches, 0);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case ADDRSW: 
                    if (!(addr = *argp++))/* allow -xyz arguments */
index 9e8da9f..607a7c2 100644 (file)
@@ -103,10 +103,10 @@ main (int argc, char **argv)
                snprintf(buf, sizeof(buf), "%s [+folder] [msgs] [switches]",
                        invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case DATESW:
                if (datesw)
index 4133f86..fef583e 100644 (file)
@@ -224,10 +224,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches] file", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case DEBUGSW: 
                    debug++;
index 12412c7..6e47ea5 100644 (file)
@@ -91,10 +91,10 @@ main (int argc, char **argv)
            case HELPSW: 
                snprintf (buf, sizeof(buf), "%s [switches]", invo_name);
                print_help (buf, switches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
     
            case TOSW:
                if (!(f1 = *argp++))
index ddfc998..bb1e6b4 100644 (file)
@@ -176,10 +176,10 @@ WhatNow (int argc, char **argv)
            case HELPSW:
                snprintf (buf, sizeof(buf), "%s [switches] [file]", invo_name);
                print_help (buf, whatnowswitches, 1);
-               done (1);
+               done (0);
            case VERSIONSW:
                print_version(invo_name);
-               done (1);
+               done (0);
 
            case DFOLDSW:
                if (dfolder)
index 24f09ef..5f0eefd 100644 (file)
@@ -105,10 +105,10 @@ main (int argc, char **argv)
                case HELPSW: 
                    snprintf (buf, sizeof(buf), "%s [switches] [file]", invo_name);
                    print_help (buf, switches, 1);
-                   done (1);
+                   done (0);
                case VERSIONSW:
                    print_version(invo_name);
-                   done (1);
+                   done (0);
 
                case CHKSW: 
                case NOCHKSW: