tp = dctime(dlocaltimenow());
snprintf (buffer, sizeof(buffer), "From %.*s %s",
(int)(fp - ep), ep, tp);
tp = dctime(dlocaltimenow());
snprintf (buffer, sizeof(buffer), "From %.*s %s",
(int)(fp - ep), ep, tp);
strncpy(tmpbuffer, buffer, sizeof(tmpbuffer));
ep = tmpbuffer + 17;
snprintf (buffer, sizeof(buffer), "From %s", ep);
strncpy(tmpbuffer, buffer, sizeof(tmpbuffer));
ep = tmpbuffer + 17;
snprintf (buffer, sizeof(buffer), "From %s", ep);
/*
* If there is already a "From " line,
* then leave it alone. Else we add one.
/*
* If there is already a "From " line,
* then leave it alone. Else we add one.
* If this is not first line, and begins with
* "From ", then prepend line with ">".
*/
* If this is not first line, and begins with
* "From ", then prepend line with ">".
*/
if (write (md, ">", 1) < 0) {
advise (mailbox, "write");
}
if (write (md, ">", 1) < 0) {
advise (mailbox, "write");
}