X-Git-Url: http://git.marmaro.de/?p=mmh;a=blobdiff_plain;f=uip%2Fmhstore.c;h=adaca774d191b82f486880013cfbc88c2e37533a;hp=4f84570227aabdb09c619d76a8ce7d368c1ffa46;hb=9cf6132a6ea29968131a000bc2fb6860affac45e;hpb=d4c34b4439a9dbd89664de460ed37ecddc260fb1 diff --git a/uip/mhstore.c b/uip/mhstore.c index 4f84570..adaca77 100644 --- a/uip/mhstore.c +++ b/uip/mhstore.c @@ -195,7 +195,7 @@ main(int argc, char **argv) if (!(cp = *argp++) || (*cp == '-' && cp[1])) adios(EX_USAGE, NULL, "missing argument to %s", argp[-2]); - file = *cp == '-' ? cp : getcpy(expanddir(cp)); + file = *cp == '-' ? cp : mh_xstrdup(expanddir(cp)); continue; case DEBUGSW: @@ -207,7 +207,7 @@ main(int argc, char **argv) if (folder) adios(EX_USAGE, NULL, "only one folder at a time!"); else - folder = getcpy(expandfol(cp)); + folder = mh_xstrdup(expandfol(cp)); } else app_msgarg(&msgs, cp); } @@ -242,7 +242,7 @@ main(int argc, char **argv) /* ** Cache the current directory before we do any chdirs()'s. */ - cwd = getcpy(pwd()); + cwd = mh_xstrdup(pwd()); /* ** Check for storage directory. If specified, @@ -252,7 +252,7 @@ main(int argc, char **argv) if ((cp = context_find(nmhstorage)) && *cp) tmp = concat(cp, "/", invo_name, NULL); else - tmp = getcpy(toabsdir(invo_name)); + tmp = mh_xstrdup(toabsdir(invo_name)); if (file && msgs.size) adios(EX_USAGE, NULL, "cannot specify msg and file at same time!"); @@ -382,9 +382,9 @@ store_all_messages(CT *cts) ** store any contents. */ if ((cp = context_find(nmhstorage)) && *cp) - dir = getcpy(cp); + dir = mh_xstrdup(cp); else - dir = getcpy(cwd); + dir = mh_xstrdup(cwd); for (ctp = cts; *ctp; ctp++) { ct = *ctp; @@ -490,7 +490,7 @@ store_generic(CT ct) if (*cp && *cp!='.' && *cp!='|' && *cp!='!' && !strchr(cp, '%')) { /* filename looks good: use it */ - ct->c_storeproc = getcpy(cp); + ct->c_storeproc = mh_xstrdup(cp); } break; } @@ -728,11 +728,11 @@ store_content(CT ct, CT p) */ if (p) { appending = 1; - ct->c_storage = getcpy(p->c_storage); + ct->c_storage = mh_xstrdup(p->c_storage); /* record the folder name */ if (p->c_folder) { - ct->c_folder = getcpy(p->c_folder); + ct->c_folder = mh_xstrdup(p->c_folder); } goto got_filename; } @@ -772,11 +772,11 @@ store_content(CT ct, CT p) /* Store content in temporary file for now */ tmpfilenam = m_mktemp(invo_name, NULL, NULL); - ct->c_storage = getcpy(tmpfilenam); + ct->c_storage = mh_xstrdup(tmpfilenam); /* Get the folder name */ if (cp[1]) - folder = getcpy(expandfol(cp)); + folder = mh_xstrdup(expandfol(cp)); else folder = getcurfol(); @@ -784,7 +784,7 @@ store_content(CT ct, CT p) create_folder(toabsdir(folder), 0, exit); /* Record the folder name */ - ct->c_folder = getcpy(folder); + ct->c_folder = mh_xstrdup(folder); if (cp[1]) mh_free0(&folder); @@ -806,7 +806,7 @@ store_content(CT ct, CT p) return show_content_aux(ct, 0, buffer + 1, dir); /* record the filename */ - ct->c_storage = getcpy(buffer); + ct->c_storage = mh_xstrdup(buffer); got_filename: /* flush the output stream */