remove WARNS=0 here, use ANSI string funcs, fix .Nm usage
This commit is contained in:
parent
6977f8a8d4
commit
73d70748a8
|
@ -1,7 +1,6 @@
|
|||
# $NetBSD: Makefile,v 1.4 1997/09/20 05:51:40 mikel Exp $
|
||||
# $NetBSD: Makefile,v 1.5 1997/10/20 02:53:02 lukem Exp $
|
||||
# @(#)Makefile 8.1 (Berkeley) 6/6/93
|
||||
|
||||
PROG= vacation
|
||||
WARNS?= 1
|
||||
|
||||
.include <bsd.prog.mk>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
.\" $NetBSD: vacation.1,v 1.7 1997/09/20 05:24:36 mikel Exp $
|
||||
.\" $NetBSD: vacation.1,v 1.8 1997/10/20 02:53:02 lukem Exp $
|
||||
.\"
|
||||
.\" Copyright (c) 1985, 1987, 1990, 1991, 1993
|
||||
.\" The Regents of the University of California. All rights reserved.
|
||||
|
@ -40,14 +40,14 @@
|
|||
.Nm vacation
|
||||
.Nd return ``I am not here'' indication
|
||||
.Sh SYNOPSIS
|
||||
.Nm vacation
|
||||
.Nm
|
||||
.Fl i
|
||||
.Op Fl r Ar interval
|
||||
.Nm vacation
|
||||
.Nm
|
||||
.Op Fl a Ar alias
|
||||
.Ar login
|
||||
.Sh DESCRIPTION
|
||||
.Nm Vacation
|
||||
.Nm
|
||||
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
|
||||
.Pa .forward
|
||||
|
@ -123,7 +123,7 @@ database in the file
|
|||
.Pa .vacation.db
|
||||
in your home directory.
|
||||
.Pp
|
||||
.Nm Vacation
|
||||
.Nm
|
||||
expects a file
|
||||
.Pa .vacation.msg ,
|
||||
in your home directory, containing a message to be sent back to each
|
||||
|
@ -141,7 +141,7 @@ please contact Keith Bostic <bostic@CS.Berkeley.EDU>.
|
|||
--eric
|
||||
.Ed
|
||||
.Pp
|
||||
.Nm Vacation
|
||||
.Nm
|
||||
reads the first line from the standard input for a
|
||||
.Ux
|
||||
.Dq From
|
||||
|
@ -152,7 +152,7 @@ includes this
|
|||
line automatically.
|
||||
.Pp
|
||||
Fatal errors, such as calling
|
||||
.Nm vacation
|
||||
.Nm
|
||||
with incorrect arguments, or with non-existent
|
||||
.Ar login Ns Ar s ,
|
||||
are logged in the system log file, using
|
||||
|
@ -169,6 +169,6 @@ message to send
|
|||
.Xr sendmail 8
|
||||
.Sh HISTORY
|
||||
The
|
||||
.Nm vacation
|
||||
.Nm
|
||||
command appeared in
|
||||
.Bx 4.3 .
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: vacation.c,v 1.10 1997/09/20 05:50:45 mikel Exp $ */
|
||||
/* $NetBSD: vacation.c,v 1.11 1997/10/20 02:53:03 lukem Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1983, 1987, 1993
|
||||
|
@ -44,7 +44,7 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 1987, 1993\n\
|
|||
#if 0
|
||||
static char sccsid[] = "@(#)vacation.c 8.2 (Berkeley) 1/26/94";
|
||||
#endif
|
||||
__RCSID("$NetBSD: vacation.c,v 1.10 1997/09/20 05:50:45 mikel Exp $");
|
||||
__RCSID("$NetBSD: vacation.c,v 1.11 1997/10/20 02:53:03 lukem Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
/*
|
||||
|
@ -331,7 +331,7 @@ junkmail()
|
|||
/*
|
||||
* recent --
|
||||
* find out if user has gotten a vacation message recently.
|
||||
* use bcopy for machines with alignment restrictions
|
||||
* use memmove for machines with alignment restrictions
|
||||
*/
|
||||
int
|
||||
recent()
|
||||
|
@ -345,13 +345,13 @@ recent()
|
|||
if ((db->get)(db, &key, &data, 0))
|
||||
next = SECSPERDAY * DAYSPERWEEK;
|
||||
else
|
||||
bcopy(data.data, &next, sizeof(next));
|
||||
memmove(&next, data.data, sizeof(next));
|
||||
|
||||
/* get record for this address */
|
||||
key.data = from;
|
||||
key.size = strlen(from);
|
||||
if (!(db->get)(db, &key, &data, 0)) {
|
||||
bcopy(data.data, &then, sizeof(then));
|
||||
memmove(&then, data.data, sizeof(then));
|
||||
if (next == (time_t)LONG_MAX || /* XXX */
|
||||
then + next > time(NULL))
|
||||
return(1);
|
||||
|
|
Loading…
Reference in New Issue