X-Git-Url: http://git.marmaro.de/?p=mmh;a=blobdiff_plain;f=uip%2Fmhn.c;h=a7644a39a893d9a5f52ecd5f1f19ba4b228718d3;hp=3f2d2623d2231cb2b197c4564196ec8cfa5774f6;hb=916690191222433a6923a4be54b0d8f6ac01bd02;hpb=56a805299de35d8924969138aef4d0f1580daa6d diff --git a/uip/mhn.c b/uip/mhn.c index 3f2d262..a7644a3 100644 --- a/uip/mhn.c +++ b/uip/mhn.c @@ -2,8 +2,6 @@ /* * mhn.c -- display, list, cache, or store the contents of MIME messages * - * $Id$ - * * This code is Copyright (c) 2002, by the authors of nmh. See the * COPYRIGHT file in the root directory of the nmh distribution for * complete copyright information. @@ -126,7 +124,6 @@ static struct swit switches[] = { /* mhparse.c */ -extern int checksw; extern char *tmp; /* directory to place temp files */ /* mhcachesbr.c */ @@ -157,9 +154,6 @@ extern int userrs; int debugsw = 0; int verbosw = 0; -/* The list of top-level contents to display */ -CT *cts = NULL; - /* * variables for mhbuild (mhn -build) */ @@ -200,12 +194,13 @@ void cache_all_messages (CT *); /* mhfree.c */ void free_content (CT); +extern CT *cts; +void freects_done (int) NORETURN; /* * static prototypes */ static RETSIGTYPE pipeser (int); -static int freectp_done (int); int @@ -221,7 +216,7 @@ main (int argc, char **argv) CT ct, *ctp; FILE *fp; - done=freectp_done; + done=freects_done; #ifdef LOCALE setlocale(LC_ALL, ""); @@ -688,7 +683,8 @@ do_cache: context_save (); /* save the context file */ } - return done (0); + done (0); + return 1; } @@ -705,17 +701,3 @@ pipeser (int i) done (1); /* NOTREACHED */ } - - -static int -freectp_done (int status) -{ - CT *ctp; - - if ((ctp = cts)) - for (; *ctp; ctp++) - free_content (*ctp); - - exit (status); - return 1; /* dead code to satisfy the compiler */ -}