summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorpst <pst@FreeBSD.org>1995-09-16 18:52:51 +0000
committerpst <pst@FreeBSD.org>1995-09-16 18:52:51 +0000
commit1c6e5f99675f7a52dc06e757df41c753fb5f0227 (patch)
tree27130a51604d21e927ef0f7b80175b0ef3102744 /bin
parentc7c302cc62d13fbb94de888397975d48f0b34ddc (diff)
downloadFreeBSD-src-1c6e5f99675f7a52dc06e757df41c753fb5f0227.zip
FreeBSD-src-1c6e5f99675f7a52dc06e757df41c753fb5f0227.tar.gz
If mail is received with no from address, invoke sendmail with
/usr/sbin/sendmail -f <> dest rather than /usr/sbin/sendmail -f dest. Submitted by: Michael Butler <imb@scgt.oz.au> Obtained from: Eric Allman <eric@cs.berkeley.edu>
Diffstat (limited to 'bin')
-rw-r--r--bin/rmail/rmail.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/rmail/rmail.c b/bin/rmail/rmail.c
index aeec46c..b45ec45 100644
--- a/bin/rmail/rmail.c
+++ b/bin/rmail/rmail.c
@@ -30,7 +30,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: rmail.c,v 1.4 1995/03/19 13:29:18 joerg Exp $
+ * $Id: rmail.c,v 1.5 1995/05/30 00:07:08 rgrimes Exp $
*/
#ifndef lint
@@ -211,6 +211,8 @@ main(argc, argv)
/* Save off from user's address; the last one wins. */
for (p = addrp; *p && !isspace(*p); ++p);
*p = '\0';
+ if (*addrp == '\0')
+ addrp = "<>";
if (from_user != NULL)
free(from_user);
if ((from_user = strdup(addrp)) == NULL)
OpenPOWER on IntegriCloud