Change link-time overriding of done() to run-time reassigning of equivalent
[mmh] / uip / mhn.c
index cfeac94..3f2d262 100644 (file)
--- a/uip/mhn.c
+++ b/uip/mhn.c
@@ -205,6 +205,7 @@ void free_content (CT);
  * static prototypes
  */
 static RETSIGTYPE pipeser (int);
+static int freectp_done (int);
 
 
 int
@@ -220,6 +221,8 @@ main (int argc, char **argv)
     CT ct, *ctp;
     FILE *fp;
 
+    done=freectp_done;
+
 #ifdef LOCALE
     setlocale(LC_ALL, "");
 #endif
@@ -427,7 +430,7 @@ do_cache:
            if (folder)
                adios (NULL, "only one folder at a time!");
            else
-               folder = path (cp + 1, *cp == '+' ? TFOLDER : TSUBCWF);
+               folder = pluspath (cp);
        } else
                app_msgarg(&msgs, cp);
     }
@@ -704,8 +707,8 @@ pipeser (int i)
 }
 
 
-int
-done (int status)
+static int
+freectp_done (int status)
 {
     CT *ctp;