X-Git-Url: http://git.marmaro.de/?p=mmh;a=blobdiff_plain;f=uip%2Fmhlistsbr.c;h=dd6264bf53e6c164902315babb51013ef7598cfe;hp=a59e0e88e5860655e220cda558aae4be705a9858;hb=6e9577f324bef90765a5edc02044eb111ec48072;hpb=2abb9a7cfb0930e27062088734d306e7d78e4cc2 diff --git a/uip/mhlistsbr.c b/uip/mhlistsbr.c index a59e0e8..dd6264b 100644 --- a/uip/mhlistsbr.c +++ b/uip/mhlistsbr.c @@ -15,6 +15,7 @@ #include #include #include +#include /* mhmisc.c */ int part_ok(CT, int); @@ -117,7 +118,7 @@ list_switch(CT ct, int toplevel, int verbose, int debug) default: /* list_debug (ct); */ - adios(NULL, "unknown content type %d", ct->c_type); + adios(EX_DATAERR, NULL, "unknown content type %d", ct->c_type); break; } @@ -173,11 +174,10 @@ list_content(CT ct, int toplevel, int verbose, int debug) /* print Content-Description */ if (ct->c_descr) { char *dp; - - dp = trimcpy(cp = getcpy(ct->c_descr)); - free(cp); + dp = trimcpy(cp = mh_xstrdup(ct->c_descr)); + mh_free0(&cp); printf(LSTFMT2d1, dp); - free(dp); + mh_free0(&dp); } printf("\n"); @@ -200,7 +200,7 @@ list_content(CT ct, int toplevel, int verbose, int debug) dp = trimcpy(cp = add(ci->ci_comment, NULL)); free (cp); snprintf(buffer, sizeof(buffer), "(%s)", dp); - free(dp); + mh_free0(&dp); printf(LSTFMT2d2, buffer); } }