change $i to $j; $i is now queue id; put "Received:" format in .cf
authorEric Allman <eric@ucbvax.Berkeley.EDU>
Mon, 23 Aug 1982 14:07:32 +0000 (06:07 -0800)
committerEric Allman <eric@ucbvax.Berkeley.EDU>
Mon, 23 Aug 1982 14:07:32 +0000 (06:07 -0800)
file; minor cleanup

SCCS-vsn: usr.sbin/sendmail/src/main.c 3.97
SCCS-vsn: usr.sbin/sendmail/src/collect.c 3.50
SCCS-vsn: usr.sbin/sendmail/src/version.c 3.163
SCCS-vsn: usr.sbin/sendmail/src/srvrsmtp.c 3.30
SCCS-vsn: usr.sbin/sendmail/src/macro.c 3.15
SCCS-vsn: usr.sbin/sendmail/src/headers.c 3.27

usr/src/usr.sbin/sendmail/src/collect.c
usr/src/usr.sbin/sendmail/src/headers.c
usr/src/usr.sbin/sendmail/src/macro.c
usr/src/usr.sbin/sendmail/src/main.c
usr/src/usr.sbin/sendmail/src/srvrsmtp.c
usr/src/usr.sbin/sendmail/src/version.c

index 90ae1df..546234a 100644 (file)
@@ -1,7 +1,7 @@
 # include <errno.h>
 # include "sendmail.h"
 
 # include <errno.h>
 # include "sendmail.h"
 
-SCCSID(@(#)collect.c   3.49            %G%);
+SCCSID(@(#)collect.c   3.50            %G%);
 
 /*
 **  COLLECT -- read & parse message header & make temp file.
 
 /*
 **  COLLECT -- read & parse message header & make temp file.
@@ -56,20 +56,6 @@ maketemp(from)
        }
        (void) chmod(CurEnv->e_df, 0600);
 
        }
        (void) chmod(CurEnv->e_df, 0600);
 
-       /*
-       **  Create the Received: line if we want to.
-       */
-
-       if (Smtp && macvalue('s') != NULL)
-       {
-               char xbuf[50];
-
-               /* this should be in the config file */
-               (void) sprintf(xbuf, "Received: from $s by $i with SMTP; $b");
-               expand(xbuf, buf, &buf[sizeof buf - 1], CurEnv);
-               (void) chompheader(buf, FALSE);
-       }
-
        /*
        **  Tell ARPANET to go ahead.
        */
        /*
        **  Tell ARPANET to go ahead.
        */
index 701c8b1..2ce4839 100644 (file)
@@ -1,7 +1,7 @@
 # include <errno.h>
 # include "sendmail.h"
 
 # include <errno.h>
 # include "sendmail.h"
 
-SCCSID(@(#)headers.c   3.26            %G%);
+SCCSID(@(#)headers.c   3.27            %G%);
 
 /*
 **  CHOMPHEADER -- process and save a header line.
 
 /*
 **  CHOMPHEADER -- process and save a header line.
@@ -365,7 +365,6 @@ eatheader()
        register HDR *h;
        register char *p;
        char buf[MAXLINE];
        register HDR *h;
        register char *p;
        char buf[MAXLINE];
-       char *msgid;
 
 # ifdef DEBUG
        if (tTd(32, 2))
 
 # ifdef DEBUG
        if (tTd(32, 2))
@@ -379,29 +378,6 @@ eatheader()
        }
 # endif DEBUG
 
        }
 # endif DEBUG
 
-       /* message id */
-       h = hrvalue("message-id");
-       if (h == NULL)
-               msgid = NULL;
-       else if (bitset(H_DEFAULT, h->h_flags))
-       {
-               (void) expand(h->h_value, buf, &buf[sizeof buf - 1], CurEnv);
-               msgid = buf;
-       }
-       else
-               msgid = h->h_value;
-       if (msgid != NULL)
-       {
-# ifdef DEBUG
-               if (tTd(32, 1))
-                       printf("Message-Id: %s\n", msgid);
-# endif DEBUG
-# ifdef LOG
-               if (LogLevel > 1)
-                       syslog(LOG_INFO, "%s: messageid=%s", CurEnv->e_id, msgid);
-# endif LOG
-       }
-
        /* message priority */
        if (!QueueRun)
        {
        /* message priority */
        if (!QueueRun)
        {
index b279472..9678f85 100644 (file)
@@ -1,7 +1,7 @@
 # include "sendmail.h"
 # include "conf.h"
 
 # include "sendmail.h"
 # include "conf.h"
 
-SCCSID(@(#)macro.c     3.14            %G%);
+SCCSID(@(#)macro.c     3.15            %G%);
 
 /*
 **  EXPAND -- macro expand a string using $x escapes.
 
 /*
 **  EXPAND -- macro expand a string using $x escapes.
@@ -159,7 +159,8 @@ expand2(s, buf, buflim, e)
 **             $f   raw from address
 **             $g   translated from address
 **             $h   to host
 **             $f   raw from address
 **             $g   translated from address
 **             $h   to host
-**             $i   official SMTP hostname, used in messages+
+**             $i   queue id
+**             $j   official SMTP hostname, used in messages+
 **             $l   UNIX-style from line+
 **             $n   name of sendmail ("MAILER-DAEMON" on local
 **                  net typically)+
 **             $l   UNIX-style from line+
 **             $n   name of sendmail ("MAILER-DAEMON" on local
 **                  net typically)+
index 839f2a5..98a048a 100644 (file)
@@ -6,7 +6,7 @@
 # include "sendmail.h"
 # include <sys/stat.h>
 
 # include "sendmail.h"
 # include <sys/stat.h>
 
-SCCSID(@(#)main.c      3.96            %G%);
+SCCSID(@(#)main.c      3.97            %G%);
 
 /*
 **  SENDMAIL -- Post mail to a set of destinations.
 
 /*
 **  SENDMAIL -- Post mail to a set of destinations.
@@ -134,7 +134,7 @@ main(argc, argv)
        typedef int (*fnptr)();
        register int i;
        bool safecf = TRUE;             /* this conf file is sys default */
        typedef int (*fnptr)();
        register int i;
        bool safecf = TRUE;             /* this conf file is sys default */
-       char ibuf[30];                  /* holds HostName */
+       char jbuf[30];                  /* holds HostName */
        bool queuemode = FALSE;         /* process queue requests */
        bool aliasinit = FALSE;
        extern bool safefile();
        bool queuemode = FALSE;         /* process queue requests */
        bool aliasinit = FALSE;
        extern bool safefile();
@@ -421,8 +421,8 @@ main(argc, argv)
        initsys();
 
        /* our name for SMTP codes */
        initsys();
 
        /* our name for SMTP codes */
-       expand("$i", ibuf, &ibuf[sizeof ibuf - 1], CurEnv);
-       HostName = ibuf;
+       expand("$j", jbuf, &jbuf[sizeof jbuf - 1], CurEnv);
+       HostName = jbuf;
 
        /* the indices of local and program mailers */
        st = stab("local", ST_MAILER, ST_FIND);
 
        /* the indices of local and program mailers */
        st = stab("local", ST_MAILER, ST_FIND);
@@ -1199,6 +1199,7 @@ queuename(e, type)
                }
                e->e_qf = newstr(qf);
                e->e_id = &e->e_qf[fx];
                }
                e->e_qf = newstr(qf);
                e->e_id = &e->e_qf[fx];
+               define('i', e->e_id);
 # ifdef DEBUG
                if (tTd(7, 1))
                        printf("queuename: assigned id %s, env=%x\n", e->e_id, e);
 # ifdef DEBUG
                if (tTd(7, 1))
                        printf("queuename: assigned id %s, env=%x\n", e->e_id, e);
index 9c80e06..4f77986 100644 (file)
@@ -1,10 +1,10 @@
 # include "sendmail.h"
 
 # ifndef SMTP
 # include "sendmail.h"
 
 # ifndef SMTP
-SCCSID(@(#)srvrsmtp.c  3.29            %G%     (no SMTP));
+SCCSID(@(#)srvrsmtp.c  3.30            %G%     (no SMTP));
 # else SMTP
 
 # else SMTP
 
-SCCSID(@(#)srvrsmtp.c  3.29            %G%);
+SCCSID(@(#)srvrsmtp.c  3.30            %G%);
 
 /*
 **  SMTP -- run the SMTP protocol.
 
 /*
 **  SMTP -- run the SMTP protocol.
@@ -90,7 +90,7 @@ smtp()
                (void) close(1);
                (void) dup(fileno(OutChannel));
        }
                (void) close(1);
                (void) dup(fileno(OutChannel));
        }
-       message("220", "%s Sendmail v%s ready at %s", HostName,
+       message("220", "%s Sendmail %s ready at %s", HostName,
                        Version, arpadate(NULL));
        (void) setjmp(TopFrame);
        QuickAbort = FALSE;
                        Version, arpadate(NULL));
        (void) setjmp(TopFrame);
        QuickAbort = FALSE;
index aabae7c..22cc1f2 100644 (file)
@@ -1,5 +1,5 @@
 # ifndef lint
 # ifndef lint
-static char    SccsId[] = "@(#)SendMail version 3.162 of %G%";
+static char    SccsId[] = "@(#)SendMail version 3.163 of %G%";
 # endif lint
 
 # endif lint
 
-char   Version[] = "3.162 [%G%]";
+char   Version[] = "3.163 [%G%]";