X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/012d05c2b62332eb400d66b806e48216d39358c6..04fe5667ca51ed208fa4ba2e6e618904e9fb8702:/uip/repl.c diff --git a/uip/repl.c b/uip/repl.c index ebe72ff2..f97210c2 100644 --- a/uip/repl.c +++ b/uip/repl.c @@ -239,8 +239,7 @@ main (int argc, char **argv) if (fcc) fcc = add (", ", fcc); fcc = add (cp, fcc); - if (dp) - free (dp); + mh_xfree(dp); continue; case FILESW: @@ -354,7 +353,7 @@ main (int argc, char **argv) if (ccme == -1) ccme = groupreply; - cwd = getcpy (pwd ()); + cwd = mh_xstrdup(pwd ()); if (!context_find ("path")) free (path ("./", TFOLDER)); @@ -370,7 +369,8 @@ try_it_again: if (!buildsw && stat (drft, &st) != NOTOK) { printf ("Draft \"%s\" exists (%ld bytes).", drft, (long) st.st_size); for (i = LISTDSW; i != YESW;) { - if (!(argp = getans ("\nDisposition? ", isdf ? aqrnl : aqrl))) + if (!(argp = read_switch_multiword ("\nDisposition? ", + isdf ? aqrnl : aqrl))) done (1); switch (i = smatch (*argp, isdf ? aqrnl : aqrl)) { case NOSW: @@ -434,7 +434,7 @@ try_it_again: context_save (); /* save the context file */ } - msg = file ? file : getcpy (m_name (mp->lowsel)); + msg = file ? file : mh_xstrdup(m_name (mp->lowsel)); if ((in = fopen (msg, "r")) == NULL) adios (msg, "unable to open");