From: Kurt A. Shoens Date: Tue, 19 May 1981 06:53:11 +0000 (-0800) Subject: added option sendmail which lets you specify what program to use to X-Git-Tag: BSD-4_1_snap-Snapshot-Development~1268 X-Git-Url: https://git.subgeniuskitty.com/unix-history/.git/commitdiff_plain/6fa89d43a833ab3f17d72daebb9aadd88ba0f9ce added option sendmail which lets you specify what program to use to actually send the mail SCCS-vsn: usr.bin/mail/send.c 1.6 --- diff --git a/usr/src/usr.bin/mail/send.c b/usr/src/usr.bin/mail/send.c index f90993eec9..4d96e7c961 100644 --- a/usr/src/usr.bin/mail/send.c +++ b/usr/src/usr.bin/mail/send.c @@ -12,7 +12,7 @@ * Mail to others. */ -static char *SccsId = "@(#)send.c 1.5 %G%"; +static char *SccsId = "@(#)send.c 1.6 %G%"; /* * Send message described by the passed pointer to the @@ -187,7 +187,7 @@ mail1(hp) { register char *cp; int pid, i, s, p, gotcha; - char **namelist; + char **namelist, *deliver; struct name *to, *np; FILE *mtf, *postage; int remote = rflag != NOSTR || rmail; @@ -326,7 +326,9 @@ topdog: submit(getpid()); #endif CC #ifdef DELIVERMAIL - execv(DELIVERMAIL, namelist); + if ((deliver = value("sendmail")) == NOSTR) + deliver = DELIVERMAIL; + execv(deliver, namelist); #endif DELIVERMAIL execv(MAIL, namelist); perror(MAIL);