


diff -r -c UK-1.4/MAKE UK-1.4a/MAKE
*** UK-1.4/MAKE	Wed Feb 12 12:20:34 1986
--- UK-1.4a/MAKE	Sat Oct 11 16:20:51 1986
***************
*** 166,171
  fi
  
  #
  #  now start creating the files
  #
  echo -n "

--- 166,184 -----
  fi
  
  #
+ #  if uucp is defined then see if we need the BSD4.3/Sun 3.0 hack
+ #
+ if [ -n "$uucpname" ]
+ then	echo -n "
+ 	Are you using bsd4.3 or Sun 3.0 sendmail? (y|n) "
+ 	read reply
+ 	if [ $reply = 'y' ]
+ 	then
+ 		bsd43=true
+ 	fi
+ fi
+ 
+ #
  #  now start creating the files
  #
  echo -n "
***************
*** 237,242
  if [ -z "$nonrsformat" ]
  then
  	echo "define(\`NRSFORMAT')" >> $host.mc
  fi
  
  if [ -n "$ethername" ]

--- 250,260 -----
  if [ -z "$nonrsformat" ]
  then
  	echo "define(\`NRSFORMAT')" >> $host.mc
+ fi
+ 
+ if [ -n "$bsd43" ]
+ then
+ 	echo "define(\`BSD4.3')" >> $host.mc
  fi
  
  if [ -n "$ethername" ]

diff -r -c UK-1.4/Mailers.a UK-1.4a/Mailers.a
*** UK-1.4/Mailers.a	Sun Apr 27 12:54:12 1986
--- UK-1.4a/Mailers.a	Sat Oct 11 16:20:46 1986
***************
*** 135,141
  S26
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@CSNETNAME		add local domain name
! uucpm.m4        508594640   217   4     100644  754       `
  ###############################################################################
  ###############################################################################
  #####

--- 135,141 -----
  S26
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@CSNETNAME		add local domain name
! uucpm.m4        526661348   217   4     100644  811       `
  ###############################################################################
  ###############################################################################
  #####
***************
*** 154,159
  #  can't produce a correct routed 822 address from another style
  #
  S23
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@UUCPNAME		add local hostname
  luucpm.m4.old   508594686   217   4     100644  594       `

--- 154,161 -----
  #  can't produce a correct routed 822 address from another style
  #
  S23
+ ifdef(`BSD4.3',
+ `R$+!$+			$@$2			return transport addr')
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@UUCPNAME		add local hostname
  
***************
*** 156,161
  S23
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@UUCPNAME		add local hostname
  luucpm.m4.old   508594686   217   4     100644  594       `
  ###############################################################################
  ###############################################################################

--- 158,164 -----
  `R$+!$+			$@$2			return transport addr')
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@UUCPNAME		add local hostname
+ 
  luucpm.m4.old   508594686   217   4     100644  594       `
  ###############################################################################
  ###############################################################################
***************
*** 173,179
  S22
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@LUUCPNAME		add local hostname
! uucpm.m4.old    508594687   217   4     100644  688       `
  ###############################################################################
  ###############################################################################
  #####

--- 176,182 -----
  S22
  R$+@$+			$@$1@$2			address ok
  R$+			$@$1@LUUCPNAME		add local hostname
! uucpm.m4.old    526661360   217   4     100644  745       `
  ###############################################################################
  ###############################################################################
  #####
***************
*** 191,196
  #  Addresses are converted back to uucp style.
  #
  S23
  R$+@$+			$:$>8$1@$2		convert to uucp style
  R$+!$+			$@$1!$2			address ok
  R$+			$@UUCPNAME!$1		add local domain name

--- 194,201 -----
  #  Addresses are converted back to uucp style.
  #
  S23
+ ifdef(`BSD4.3',
+ `R$+!$+			$@$2			return transport addr')
  R$+@$+			$:$>8$1@$2		convert to uucp style
  R$+!$+			$@$1!$2			address ok
  R$+			$@UUCPNAME!$1		add local domain name
***************
*** 194,196
  R$+@$+			$:$>8$1@$2		convert to uucp style
  R$+!$+			$@$1!$2			address ok
  R$+			$@UUCPNAME!$1		add local domain name

--- 199,202 -----
  R$+@$+			$:$>8$1@$2		convert to uucp style
  R$+!$+			$@$1!$2			address ok
  R$+			$@UUCPNAME!$1		add local domain name
+ 

diff -r -c UK-1.4/Rules.a UK-1.4a/Rules.a
*** UK-1.4/Rules.a	Fri Feb 21 11:14:04 1986
--- UK-1.4a/Rules.a	Tue Oct 14 11:45:44 1986
***************
*** 1,5
  !<arch>
! base.m4         508594731   217   4     100644  3142      `
  ##################################################################
  ##################################################################
  #####

--- 1,5 -----
  !<arch>
! base.m4         529670681   217   4     100644  3146      `
  ##################################################################
  ##################################################################
  #####
***************
*** 45,51
  # delimiter (operator) characters (note '~' has been added)
  Do.:%@!^=/[]~
  # format of a total name
! Dq$?x$x $.<$g>
  # SMTP login message
  De$j Sendmail $v/$V ready at $b
  

--- 45,51 -----
  # delimiter (operator) characters (note '~' has been added)
  Do.:%@!^=/[]~
  # format of a total name
! Dq$?x$x <$g>$|$g$.
  # SMTP login message
  De$j Sendmail $v/$V ready at $b
  
***************
*** 116,122
  H?D?Date: $a
  H?M?Message-Id: <$p.$t@$j>
  H?F?Resent-From: $q
! H?D?Resent-Date: $a
  H?M?Resent-Message-Id: <$p.$t@$j>
  HSubject:
  H?R?Received: $?sfrom $s by $j; $b$.

--- 116,122 -----
  H?D?Date: $a
  H?M?Message-Id: <$p.$t@$j>
  H?F?Resent-From: $q
! H?D?Resent-Date: $b
  H?M?Resent-Message-Id: <$p.$t@$j>
  HSubject:
  H?R?Received: $?sfrom $s by $j; $b$.
***************
*** 141,147
  ifdef(`JANETNAME',`include(hhcpm.m4)')
  ifdef(`BITNETNAME',`include(bitnetm.m4)')
  ifdef(`CSNETNAME',`include(pmdfm.m4)')
! rules.m4        508594751   217   4     100644  3240      `
  ###############################################################################
  ###############################################################################
  #####

--- 141,147 -----
  ifdef(`JANETNAME',`include(hhcpm.m4)')
  ifdef(`BITNETNAME',`include(bitnetm.m4)')
  ifdef(`CSNETNAME',`include(pmdfm.m4)')
! rules.m4        526661238   217   4     100644  3263      `
  ###############################################################################
  ###############################################################################
  #####
***************
*** 179,185
  ')
  ifdef(`UUCPNAME',`
  R<~$+>$+.uucp		<\\~$1>$2.uucp		band-aid for uuxqt
! R<$+>$-.uucp		$#uucp$@$2$:$1		external uucp mail
  ')
  ifdef(`JANETNAME',`
  R<$+>$+.janet		$#hhcp$@$2$:$1		janet mail

--- 179,185 -----
  ')
  ifdef(`UUCPNAME',`
  R<~$+>$+.uucp		<\\~$1>$2.uucp		band-aid for uuxqt
! R<$+>$-.uucp		$#uucp$@$2$:'ifdef(`BSD4.3',`$2!')`$1		external uucp mail
  ')
  ifdef(`JANETNAME',`
  R<$+>$+.janet		$#hhcp$@$2$:$1		janet mail
***************
*** 254,259
  #  this ensures that $u has at least one '@' in (if percent style)
  R$+%$+			$1@$2			convert '%'s to '@'s
  R$+@$+@$+		$1%$2@$3		then reduce to only one '@'
  rules1.m4       508594753   217   4     100644  3447      `
  ###############################################################################
  ###############################################################################

--- 254,260 -----
  #  this ensures that $u has at least one '@' in (if percent style)
  R$+%$+			$1@$2			convert '%'s to '@'s
  R$+@$+@$+		$1%$2@$3		then reduce to only one '@'
+ 
  rules1.m4       508594753   217   4     100644  3447      `
  ###############################################################################
  ###############################################################################
***************
*** 357,363
  R$*@$-:$+.$+		$1@$3.$2.$4		u@b:c:d.a -> u@d.c.b.a
  ')
  
! version.m4      508594758   217   4     100644  3257      `
  #
  #	@(#)version.m4	UK-1.4 sendmail configuration		12/2/86
  #

--- 358,364 -----
  R$*@$-:$+.$+		$1@$3.$2.$4		u@b:c:d.a -> u@d.c.b.a
  ')
  
! version.m4      529253061   217   4     100644  3563      `
  #
  #	@(#)version.m4	UK-1.4 sendmail configuration		12/2/86
  #
***************
*** 362,368
  #	@(#)version.m4	UK-1.4 sendmail configuration		12/2/86
  #
  
! DVUK-1.4
  
  #
  #	UK-1.4  12/2/86		jim

--- 363,369 -----
  #	@(#)version.m4	UK-1.4 sendmail configuration		12/2/86
  #
  
! DVUK-1.4a
  
  #
  #	UK-1.4a 9/10/86		jim
***************
*** 364,369
  
  DVUK-1.4
  
  #
  #	UK-1.4  12/2/86		jim
  #	COMMENTS:

--- 365,377 -----
  
  DVUK-1.4a
  
+ #
+ #	UK-1.4a 9/10/86		jim
+ #	COMMENTS:
+ #	Band-aid for BSD4.3 (& Sun 3.0). The transport address goes through
+ #	the header rulesets (big sigh) so have to do a kludge for uucp.
+ #	$a -> $b in Resent-Date field: this seems to be what you want.
+ #	change to $q: don't emit angle brackets if full name is unknown.
  #
  #	UK-1.4  12/2/86		jim
  #	COMMENTS:

diff -r -c UK-1.4/Support/muucp.c UK-1.4a/Support/muucp.c
*** UK-1.4/Support/muucp.c	Sun Feb  9 13:56:14 1986
--- UK-1.4a/Support/muucp.c	Sat Oct 11 16:20:58 1986
***************
*** 13,18
  fprintf(f, "S %s %s %s -%s %s 0666\n", a, b, c, d, e);\
  }
  
  
  main(argc, argv)
  char *argv[];

--- 13,21 -----
  fprintf(f, "S %s %s %s -%s %s 0666\n", a, b, c, d, e);\
  }
  
+ #ifndef SYSINFO
+ #define mapname(x)	x
+ #endif SYSINFO
  
  main(argc, argv)
  char *argv[];

diff -r -c UK-1.4/chn/README UK-1.4a/chn/README
*** UK-1.4/chn/README	Mon Mar 17 13:28:07 1986
--- UK-1.4a/chn/README	Sat Oct 11 16:20:54 1986
***************
*** 155,162
  To do this we need to "generalise" the host dependent parts of the
  channel tables so that all the workstations can use the same <host>.chn.
  
! The trick is to use "$w" when specifying the host specific names in the
! local.chn table (e.g. $w.cs.hw.ac.uk);  and to have, in above example,
  all ten workstations in the ether.chn.
  
  The two key components to this are that: (a) sendmail will determine

--- 155,162 -----
  To do this we need to "generalise" the host dependent parts of the
  channel tables so that all the workstations can use the same <host>.chn.
  
! The trick is to use "$=w" when specifying the host specific names in the
! local.chn table (e.g. $=w.cs.hw.ac.uk);  and to have, in above example,
  all ten workstations in the ether.chn.
  
  The two key components to this are that: (a) sendmail will determine
***************
*** 161,165
  
  The two key components to this are that: (a) sendmail will determine
  whether a domain is local or not before it attempts to locate the
! domain in the other channel tables, and (b) sendmail's "$w" macro expands
  to the local hostname at runtime.

--- 161,165 -----
  
  The two key components to this are that: (a) sendmail will determine
  whether a domain is local or not before it attempts to locate the
! domain in the other channel tables, and (b) sendmail's "$=w" class expands
  to the local hostname at runtime.

diff -r -c UK-1.4/xtras/hhmailclean.c UK-1.4a/xtras/hhmailclean.c
*** UK-1.4/xtras/hhmailclean.c	Fri Mar 21 15:33:29 1986
--- UK-1.4a/xtras/hhmailclean.c	Sun Oct 12 11:16:12 1986
***************
*** 120,126
  
  	strcpy(pafile,pbfile);
  	pafile[1] = 'A';
! 	host = gethost(pafile);
  
  	if ((msgfp = fopen(pbfile, "r")) == NULL)
  		return;

--- 120,127 -----
  
  	strcpy(pafile,pbfile);
  	pafile[1] = 'A';
! 	if ((host = gethost(pafile)) == NULL)
! 		return;
  
  	if ((msgfp = fopen(pbfile, "r")) == NULL)
  		return;
***************
*** 158,164
  
  	strcpy(pafile,pbfile);
  	pafile[1] = 'A';
! 	host = gethost(pafile);
  
  	if ((msgfp = fopen(pbfile, "r")) == NULL)
  		return;

--- 159,166 -----
  
  	strcpy(pafile,pbfile);
  	pafile[1] = 'A';
! 	if ((host = gethost(pafile)) == NULL)
! 		return;
  
  	if ((msgfp = fopen(pbfile, "r")) == NULL)
  		return;
***************
*** 267,273
  	while (fgets(buf, BUFSIZ, msgfp) != NULL && buf[0] != '\n')
  	{	/*
  		 *  extract sender from one of the following headers,
! 		 *  in order of preference: "Reply-To", "Sender", "From"
  		 */
  		if (strncmp(buf, "Reply-To:", 9) == 0)
  		{	strcpy(sndbuf, &buf[9]);

--- 269,275 -----
  	while (fgets(buf, BUFSIZ, msgfp) != NULL && buf[0] != '\n')
  	{	/*
  		 *  extract sender from one of the following headers,
! 		 *  in order of preference: "Errors-To", "Sender", "From"
  		 */
  		if (strncmp(buf, "Errors-To:", 10) == 0)
  		{	strcpy(sndbuf, &buf[10]);
***************
*** 269,276
  		 *  extract sender from one of the following headers,
  		 *  in order of preference: "Reply-To", "Sender", "From"
  		 */
! 		if (strncmp(buf, "Reply-To:", 9) == 0)
! 		{	strcpy(sndbuf, &buf[9]);
  			saved = 2;
  		}
  		else if (saved < 2 && strncmp(buf, "Sender:", 7) == 0)

--- 271,278 -----
  		 *  extract sender from one of the following headers,
  		 *  in order of preference: "Errors-To", "Sender", "From"
  		 */
! 		if (strncmp(buf, "Errors-To:", 10) == 0)
! 		{	strcpy(sndbuf, &buf[10]);
  			saved = 2;
  		}
  		else if (saved < 2 && strncmp(buf, "Sender:", 7) == 0)

