Fix conflicts from sendmail 8.12.3 import

This commit is contained in:
gshapiro 2002-04-10 03:06:22 +00:00
parent 8a84931eaf
commit 74e8a586dc
5 changed files with 119 additions and 42 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.
* Copyright (c) 1998-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
* Copyright (c) 1990, 1993, 1994
* The Regents of the University of California. All rights reserved.
@ -18,7 +18,7 @@ SM_IDSTR(copyright,
Copyright (c) 1990, 1993, 1994\n\
The Regents of the University of California. All rights reserved.\n")
SM_IDSTR(id, "@(#)$Id: mail.local.c,v 8.235 2001/12/30 04:59:39 gshapiro Exp $")
SM_IDSTR(id, "@(#)$Id: mail.local.c,v 8.238 2002/03/30 07:43:21 geir Exp $")
#include <stdlib.h>
#include <sm/errstring.h>

View File

@ -13,7 +13,7 @@
#include <sendmail.h>
SM_RCSID("@(#)$Id: conf.c,v 8.939 2002/01/09 17:26:28 gshapiro Exp $")
SM_RCSID("@(#)$Id: conf.c,v 8.961 2002/04/04 21:32:14 gshapiro Exp $")
/* $FreeBSD$ */
@ -526,9 +526,15 @@ setupmaps()
#if NAMED_BIND
# if DNSMAP
# if _FFR_DNSMAP_ALIASABLE
MAPDEF("dns", NULL, MCF_ALIASOK,
dns_map_parseargs, dns_map_open, null_map_close,
dns_map_lookup, null_map_store);
# else /* _FFR_DNSMAP_ALIASABLE */
MAPDEF("dns", NULL, 0,
dns_map_parseargs, dns_map_open, null_map_close,
dns_map_lookup, null_map_store);
# endif /* _FFR_DNSMAP_ALIASABLE */
# endif /* DNSMAP */
#endif /* NAMED_BIND */
@ -3014,6 +3020,7 @@ static char *DefaultUserShells[] =
"/bin/pam",
"/usr/bin/keysh", /* key shell (extended Korn shell) */
"/bin/posix/sh",
"/sbin/sh"
# endif /* V4FS */
# endif /* __hpux */
# if defined(_AIX3) || defined(_AIX4)
@ -3484,13 +3491,12 @@ lockfile(fd, filename, ext, type)
if (!bitset(LOCK_NB, type) ||
(save_errno != EACCES && save_errno != EAGAIN))
{
int omode = -1;
# ifdef F_GETFL
(void) fcntl(fd, F_GETFL, &omode);
int omode = fcntl(fd, F_GETFL, 0);
uid_t euid = geteuid();
errno = save_errno;
# endif /* F_GETFL */
syserr("cannot lockf(%s%s, fd=%d, type=%o, omode=%o, euid=%d)",
filename, ext, fd, type, omode, geteuid());
filename, ext, fd, type, omode, euid);
dumpfd(fd, true, true);
}
# else /* !HASFLOCK */
@ -3515,13 +3521,12 @@ lockfile(fd, filename, ext, type)
if (!bitset(LOCK_NB, type) || save_errno != EWOULDBLOCK)
{
int omode = -1;
# ifdef F_GETFL
(void) fcntl(fd, F_GETFL, &omode);
int omode = fcntl(fd, F_GETFL, 0);
uid_t euid = geteuid();
errno = save_errno;
# endif /* F_GETFL */
syserr("cannot flock(%s%s, fd=%d, type=%o, omode=%o, euid=%d)",
filename, ext, fd, type, omode, geteuid());
filename, ext, fd, type, omode, euid);
dumpfd(fd, true, true);
}
# endif /* !HASFLOCK */
@ -5418,7 +5423,7 @@ link(source, target)
left -= writelen;
p += writelen;
}
if (writeln < 0)
if (writelen < 0)
break;
}
@ -5577,6 +5582,9 @@ char *CompileOptions[] =
#if USERDB
"USERDB",
#endif /* USERDB */
#if USE_LDAP_INIT
"USE_LDAP_INIT",
#endif /* USE_LDAP_INIT */
#if XDEBUG
"XDEBUG",
#endif /* XDEBUG */
@ -5806,6 +5814,9 @@ char *FFRCompileOptions[] =
#if _FFR_ALLOW_SASLINFO
"_FFR_ALLOW_SASLINFO",
#endif /* _FFR_ALLOW_SASLINFO */
#if _FFR_ALLOW_S0_ERROR_4XX
"_FFR_ALLOW_S0_ERROR_4XX",
#endif /* _FFR_ALLOW_S0_ERROR_4XX */
#if _FFR_BESTMX_BETTER_TRUNCATION
"_FFR_BESTMX_BETTER_TRUNCATION",
#endif /* _FFR_BESTMX_BETTER_TRUNCATION */
@ -5816,6 +5827,9 @@ char *FFRCompileOptions[] =
#if _FFR_CATCH_BROKEN_MTAS
"_FFR_CATCH_BROKEN_MTAS",
#endif /* _FFR_CATCH_BROKEN_MTAS */
#if _FFR_CATCH_LONG_STRINGS
"_FFR_CATCH_LONG_STRINGS",
#endif /* _FFR_CATCH_LONG_STRINGS */
#if _FFR_CHECK_EOM
"_FFR_CHECK_EOM",
#endif /* _FFR_CHECK_EOM */
@ -5828,6 +5842,14 @@ char *FFRCompileOptions[] =
#if _FFR_DEPRECATE_MAILER_FLAG_I
"_FFR_DEPRECATE_MAILER_FLAG_I",
#endif /* _FFR_DEPRECATE_MAILER_FLAG_I */
#if _FFR_DIGUNIX_SAFECHOWN
/* Problem noted by Anne Bennett of Concordia University */
"_FFR_DIGUNIX_SAFECHOWN",
#endif /* _FFR_DIGUNIX_SAFECHOWN */
#if _FFR_DNSMAP_ALIASABLE
/* Don Lewis of TDK */
"_FFR_DNSMAP_ALIASABLE",
#endif /* _FFR_DNSMAP_ALIASABLE */
#if _FFR_DNSMAP_BASE
"_FFR_DNSMAP_BASE",
#endif /* _FFR_DNSMAP_BASE */
@ -5840,6 +5862,10 @@ char *FFRCompileOptions[] =
#if _FFR_DONTLOCKFILESFORREAD_OPTION
"_FFR_DONTLOCKFILESFORREAD_OPTION",
#endif /* _FFR_DONTLOCKFILESFORREAD_OPTION */
# if _FFR_DONT_STOP_LOOKING
/* Noted by Neil Rickert of Northern Illinois University */
"_FFR_DONT_STOP_LOOKING",
# endif /* _FFR_DONT_STOP_LOOKING */
#if _FFR_DOTTED_USERNAMES
"_FFR_DOTTED_USERNAMES",
#endif /* _FFR_DOTTED_USERNAMES */
@ -5858,6 +5884,10 @@ char *FFRCompileOptions[] =
#if _FFR_GROUPREADABLEAUTHINFOFILE
"_FFR_GROUPREADABLEAUTHINFOFILE",
#endif /* _FFR_GROUPREADABLEAUTHINFOFILE */
#if _FFR_HANDLE_ISO8859_GECOS
/* Peter Eriksson of Linkopings universitet */
"_FFR_HANDLE_ISO8859_GECOS",
#endif /* _FFR_HANDLE_ISO8859_GECOS */
#if _FFR_HDR_TYPE
"_FFR_HDR_TYPE",
#endif /* _FFR_HDR_TYPE */
@ -5868,8 +5898,15 @@ char *FFRCompileOptions[] =
"_FFR_IGNORE_EXT_ON_HELO",
#endif /* _FFR_IGNORE_EXT_ON_HELO */
#if _FFR_LDAP_RECURSION
/* Andrew Baucom */
"_FFR_LDAP_RECURSION",
#endif /* _FFR_LDAP_RECURSION */
#if _FFR_LDAP_SETVERSION
"_FFR_LDAP_SETVERSION",
#endif /* _FFR_LDAP_SETVERSION */
#if _FFR_LDAP_URI
"_FFR_LDAP_URI",
#endif /* _FFR_LDAP_URI */
#if _FFR_MAX_FORWARD_ENTRIES
/* Randall S. Winchester of the University of Maryland */
"_FFR_MAX_FORWARD_ENTRIES",
@ -5892,9 +5929,16 @@ char *FFRCompileOptions[] =
#if _FFR_QUEUEDELAY
"_FFR_QUEUEDELAY",
#endif /* _FFR_QUEUEDELAY */
#if _FFR_QUEUE_GROUP_SORTORDER
/* XXX: Still need to actually use qgrp->qg_sortorder */
"_FFR_QUEUE_GROUP_SORTORDER",
#endif /* _FFR_QUEUE_GROUP_SORTORDER */
#if _FFR_QUEUE_MACRO
"_FFR_QUEUE_MACRO",
#endif /* _FFR_QUEUE_MACRO */
#if _FFR_QUEUE_RUN_PARANOIA
"_FFR_QUEUE_RUN_PARANOIA",
#endif /* _FFR_QUEUE_RUN_PARANOIA */
#if _FFR_QUEUE_SCHED_DBG
"_FFR_QUEUE_SCHED_DBG",
#endif /* _FFR_QUEUE_SCHED_DBG */
@ -5907,6 +5951,9 @@ char *FFRCompileOptions[] =
#if _FFR_RHS
"_FFR_RHS",
#endif /* _FFR_RHS */
#if _FFR_SELECT_SHM
"_FFR_SELECT_SHM",
#endif /* _FFR_SELECT_SHM */
#if _FFR_SHM_STATUS
"_FFR_SHM_STATUS",
#endif /* _FFR_SHM_STATUS */
@ -5925,6 +5972,10 @@ char *FFRCompileOptions[] =
#if _FFR_TRUSTED_QF
"_FFR_TRUSTED_QF",
#endif /* _FFR_TRUSTED_QF */
#if _FFR_USE_SETLOGIN
/* Peter Philipp */
"_FFR_USE_SETLOGIN",
#endif /* _FFR_USE_SETLOGIN */
NULL
};

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.
* Copyright (c) 1998-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
* Copyright (c) 1983, 1995-1997 Eric P. Allman. All rights reserved.
* Copyright (c) 1988, 1993
@ -10,7 +10,7 @@
* the sendmail distribution.
*
*
* $Id: conf.h,v 8.557 2001/10/05 03:49:41 ca Exp $
* $Id: conf.h,v 8.560 2002/03/15 06:01:54 geir Exp $
*/
/* $FreeBSD$ */

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1998-2001 Sendmail, Inc. and its suppliers.
* Copyright (c) 1998-2002 Sendmail, Inc. and its suppliers.
* All rights reserved.
* Copyright (c) 1995-1997 Eric P. Allman. All rights reserved.
* Copyright (c) 1988, 1993
@ -15,7 +15,7 @@
#include <sendmail.h>
SM_RCSID("@(#)$Id: mci.c,v 8.202 2001/11/05 22:12:17 ca Exp $")
SM_RCSID("@(#)$Id: mci.c,v 8.204 2002/02/22 18:24:57 ca Exp $")
#if NETINET || NETINET6
# include <arpa/inet.h>
@ -159,7 +159,7 @@ mci_scan(savemci)
bestmci = &MciCache[i];
continue;
}
if ((mci->mci_lastuse + MciCacheTimeout < now ||
if ((mci->mci_lastuse + MciCacheTimeout <= now ||
(mci->mci_mailer != NULL &&
mci->mci_mailer->m_maxdeliveries > 0 &&
mci->mci_deliveries + 1 >= mci->mci_mailer->m_maxdeliveries))&&
@ -390,7 +390,7 @@ mci_get(host, m)
time_t now = curtime();
/* if this info is stale, ignore it */
if (now > mci->mci_lastuse + MciInfoTimeout)
if (mci->mci_lastuse + MciInfoTimeout <= now)
{
mci->mci_lastuse = now;
mci->mci_errno = 0;
@ -512,7 +512,6 @@ static struct mcifbits MciFlags[] =
{ MCIF_SIZE, "SIZE" },
{ MCIF_8BITMIME, "8BITMIME" },
{ MCIF_7BIT, "7BIT" },
{ MCIF_MULTSTAT, "MULTSTAT" },
{ MCIF_INHEADER, "INHEADER" },
{ MCIF_CVT8TO7, "CVT8TO7" },
{ MCIF_DSN, "DSN" },
@ -1313,7 +1312,7 @@ mci_purge_persistent(pathname, hostname)
pathname, sm_errstring(errno));
return ret;
}
if (curtime() - statbuf.st_mtime < MciInfoTimeout)
if (curtime() - statbuf.st_mtime <= MciInfoTimeout)
return 1;
if (hostname != NULL)
{

View File

@ -9,14 +9,14 @@
.\" the sendmail distribution.
.\"
.\"
.\" $Id: vacation.1,v 8.26 2001/11/21 04:21:35 gshapiro Exp $
.\" $Id: vacation.1,v 8.29 2002/03/23 19:17:36 gshapiro Exp $
.\"
.\" $FreeBSD$
.\"
.TH VACATION 1 "$Date: 2001/11/21 04:21:35 $"
.TH VACATION 1 "$Date: 2002/03/23 19:17:36 $"
.SH NAME
vacation
\- return ``I am not here'' indication
\- E-mail auto-responder
.SH SYNOPSIS
.B vacation
.RB [ \-a
@ -43,8 +43,14 @@ vacation
.I login
.SH DESCRIPTION
.B Vacation
returns a message to the sender of a message telling them that you
are currently not reading your mail. The intended use is in a
returns a message,
.IR ~/.vacation.msg
by default, to the sender informing them that you are currently not
reading your mail.
The message is only sent to each sender once per reply interval (see
.B \-r
below).
The intended use is in a
.I .forward
file. For example, your
.I .forward
@ -82,6 +88,9 @@ with incorrect arguments, or with non-existent
.IR login s,
are logged in the system log file, using
syslog(8).
This should only be used on the command line, not in your
.I .forward
file.
.TP
.BI \-f " filename"
Use
@ -99,11 +108,24 @@ Initialize the vacation database files. It should be used
before you modify your
.I .forward
file.
This should only be used on the command line, not in your
.I .forward
file.
.TP
.B \-I
Same as
.B \-i
(for backwards compatibility).
This should only be used on the command line, not in your
.I .forward
file.
.TP
.B \-l
List the content of the vacation database file including the address
and the associated time of the last auto-response to that address.
This should only be used on the command line, not in your
.I .forward
file.
.TP
.BI \-m " filename"
Use
@ -114,10 +136,6 @@ Unless the
.I filename
starts with / it is relative to ~.
.TP
.B \-l
List the content of the vacation database file including the address
and the associated time of the last auto-response to that address.
.TP
.BI \-r " interval"
Set the reply interval to
.I interval
@ -126,6 +144,12 @@ An interval of ``0'' or
``infinite''
(actually, any non-numeric character) will never send more than
one reply.
The
.B \-r
option should only be used when the vacation database is initialized
(see
.B \-i
above).
.TP
.BI \-s " address"
Use
@ -146,13 +170,16 @@ The -f and -m options must be used to specify the database and message file
since there is no home directory for the default settings for these options.
.TP
.B \-x
reads an exclusion list from stdin (one address per line).
Reads an exclusion list from stdin (one address per line).
Mails coming from an address
in this exclusion list won't get a reply by
.BR vacation .
It is possible to exclude complete domains by specifying
``@domain''
as element of the exclusion list.
This should only be used on the command line, not in your
.I .forward
file.
.TP
.B \-z
Set the sender of the vacation message to
@ -161,6 +188,16 @@ instead of the user.
This probably violates the RFCs since vacation messages are
not required by a standards-track RFC to have a null reverse-path.
.PP
.B Vacation
reads the first line from the standard input for a
UNIX
``From''
line to determine the sender.
Sendmail(8)
includes this
``From''
line automatically.
.PP
No message will be sent unless
.I login
(or an
@ -215,16 +252,6 @@ I am on vacation until July 22. If you have something urgent,
please contact Keith Bostic <bostic@CS.Berkeley.EDU>.
--eric
.fi
.PP
.B Vacation
reads the first line from the standard input for a
UNIX
``From''
line to determine the sender.
Sendmail(8)
includes this
``From''
line automatically.
.SH FILES
.TP 1.8i
~/.vacation.db