head 1.2; access; symbols; locks; strict; comment @ * @; 1.2 date 92.12.15.00.20.22; author jromine; state Exp; branches; next 1.1; 1.1 date 92.02.10.17.03.18; author jromine; state Exp; branches; next ; desc @@ 1.2 log @endif sugar @ text @/* refile.c - refile the draft into another folder */ #ifndef lint static char ident[] = "@@(#)$Id: refile.c,v 1.1 1992/02/10 17:03:18 jromine Exp jromine $"; #endif /* lint */ #include "../h/mh.h" #include int refile (arg, file) register char **arg, *file; { int pid; register int vecp; char *vec[MAXARGS]; vecp = 0; vec[vecp++] = r1bindex (fileproc, '/'); vec[vecp++] = "-nolink"; /* override bad .mh_profile defaults */ vec[vecp++] = "-nopreserve"; vec[vecp++] = "-file"; vec[vecp++] = file; if (arg) while (*arg) vec[vecp++] = *arg++; vec[vecp] = NULL; m_update (); (void) fflush (stdout); switch (pid = vfork ()) { case NOTOK: advise ("fork", "unable to"); return NOTOK; case OK: execvp (fileproc, vec); fprintf (stderr, "unable to exec "); perror (fileproc); _exit (-1); default: return (pidwait (pid, NOTOK)); } } @ 1.1 log @Initial revision @ text @d3 2 a4 2 static char ident[] = "@@(#)$Id: m_getdefs.c,v 1.4 1992/02/03 17:50:47 jromine Exp $"; #endif lint @