]> diplodocus.org Git - nmh/commitdiff
mhlistsbr.c: Replace list_application() with body at call site.
authorRalph Corderoy <ralph@inputplus.co.uk>
Wed, 23 Aug 2017 20:20:25 +0000 (21:20 +0100)
committerRalph Corderoy <ralph@inputplus.co.uk>
Wed, 23 Aug 2017 22:31:41 +0000 (23:31 +0100)
list_application()'s comment said the function didn't need to exist.
It's correct, so delete it.  The sole caller now calls list_content(),
as list_application() used to do.  That's actually the same as other
cases in the switch so merge them.  There is a slight difference:
list_application() used to call list_content() and then return OK
regardless, now it returns list_content()'s value, but that's always OK
too.

uip/mhlistsbr.c

index f7ecbc8..a96843d 100644 (file)
@@ -27,7 +27,6 @@ static int list_debug (CT);
 static int list_multi (CT, int, int, int, int, int);
 static int list_partial (CT, int, int, int, int, int);
 static int list_external (CT, int, int, int, int, int);
 static int list_multi (CT, int, int, int, int, int);
 static int list_partial (CT, int, int, int, int, int);
 static int list_external (CT, int, int, int, int, int);
-static int list_application (CT, int, int, int, int, int);
 static int list_encoding (CT);
 
 
 static int list_encoding (CT);
 
 
@@ -121,12 +120,9 @@ list_switch (CT ct, int toplevel, int realsize, int verbose, int debug,
        case CT_AUDIO:
        case CT_IMAGE:
        case CT_VIDEO:
        case CT_AUDIO:
        case CT_IMAGE:
        case CT_VIDEO:
-           return list_content (ct, toplevel, realsize, verbose, debug, dispo);
-
        case CT_APPLICATION:
        default:
        case CT_APPLICATION:
        default:
-           return list_application (ct, toplevel, realsize, verbose, debug,
-                                    dispo);
+            return list_content (ct, toplevel, realsize, verbose, debug, dispo);
     }
 
     return 0;  /* NOT REACHED */
     }
 
     return 0;  /* NOT REACHED */
@@ -419,23 +415,6 @@ list_external (CT ct, int toplevel, int realsize, int verbose, int debug,
 }
 
 
 }
 
 
-/*
- * list content information for type "application"
- * This no longer needs to be a separate function.  It used to
- * produce some output with verbose enabled, but that has been
- * moved to list_content ().
- */
-
-static int
-list_application (CT ct, int toplevel, int realsize, int verbose, int debug,
-                 int dispo)
-{
-    list_content (ct, toplevel, realsize, verbose, debug, dispo);
-
-    return OK;
-}
-
-
 /*
  * list information about the Content-Transfer-Encoding
  * used by a content.
 /*
  * list information about the Content-Transfer-Encoding
  * used by a content.