Changed exit status of each nmh command's -version and -help switches
[mmh] / uip / fmtdump.c
index 2abf05e..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 == '-')
@@ -354,6 +354,7 @@ f_typestr(int t)
        case FT_STRF: return("STRF");
        case FT_STRFW: return("STRFW");
        case FT_PUTADDR: return("PUTADDR");
+       case FT_STRLIT: return("STRLIT");
        case FT_LS_COMP: return("LS_COMP");
        case FT_LS_LIT: return("LS_LIT");
        case FT_LS_GETENV: return("LS_GETENV");
@@ -408,6 +409,7 @@ f_typestr(int t)
        case FT_PARSEDATE: return("PARSEDATE");
        case FT_PARSEADDR: return("PARSEADDR");
        case FT_FORMATADDR: return("FORMATADDR");
+       case FT_CONCATADDR: return("CONCATADDR");
        case FT_MYMBOX: return("MYMBOX");
 #ifdef FT_ADDTOSEQ
        case FT_ADDTOSEQ: return("ADDTOSEQ");
@@ -468,13 +470,14 @@ c_flagsstr(int t)
        static char buf[64];
 
        buf[0] = '\0';
-       if (t & ~(CF_TRUE|CF_PARSED|CF_DATEFAB))
+       if (t & ~(CF_TRUE|CF_PARSED|CF_DATEFAB|CF_TRIMMED))
                printf(buf, "0x%x ", t);
        strcat(buf, "<");
        i = 0;
        FNORD(CF_TRUE, "TRUE");
        FNORD(CF_PARSED, "PARSED");
        FNORD(CF_DATEFAB, "DATEFAB");
+       FNORD(CF_TRIMMED, "TRIMMED");
        strcat(buf, ">");
        return(buf);
 }