History log of /freebsd-current/bin/date/vary.c
Revision Date Author Comments
# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# 4ef3964b 03-Jul-2023 Pedro F. Giffuni <pfg@FreeBSD.org>

bin/date: Upgrade calculations (take 2)

Use uint64_t instead of long, as this type is not correct for platforms like i386 or armv7.

Pointed out by: imp


# 4456846a 02-Jul-2023 Pedro F. Giffuni <pfg@FreeBSD.org>

bin/date: Upgrade calculations

Use long instead of int for numerous calculations, fixing a number of
date calculation overflow issues.

Obtained from: DragonflyBSD
Git log: 4238ce6f0c6df33ce677ae298b245c62cd60fb43 (only partial)


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# d3e240cb 09-Aug-2004 Yaroslav Tykhiy <ytykhiy@gmail.com>

Change the behaviour of `-v' so that, e.g., stepping a month back
on March 31 won't take you to March 2 or 3 (now the result will
be the last day of February.)

In general, now stepping by months from the last days of the current
month A will take you to the very last day of the target month B if
B is shorter than A.

The previous version would just step to March 31 and rely on mktime(3)
to correct the date. Despite its simplicity, such way was counter-intuitive
to users and caused pain to shell script writers.

Noticed by: Igor Timkin <ivt at gamma dot ru>
Approved by: brian
MFC after: 2 weeks


# 5eb43ac2 29-Jun-2002 David E. O'Brien <obrien@FreeBSD.org>

Consistently use __FBSDID


# 9afa09cd 22-Feb-2002 Mark Murray <markm@FreeBSD.org>

Fix warnings inspired by lint, a commercial lint and WARNS=4.


# 6e4cd31d 01-Dec-2000 Brian Somers <brian@FreeBSD.org>

Exit if malloc() returns NULL

Submitted by: Chris Faulhaber <jedgar@fxp.org>


# 7ecff35b 23-May-2000 Brian Somers <brian@FreeBSD.org>

Propogate the ``call mktime'' flag from adjwday() down to adjday().

Submitted by: Christian Weisgerber <naddy@mips.inka.de>


# 9263db41 12-Apr-2000 Brian Somers <brian@FreeBSD.org>

Change -v so that variences in units of days or less are sensitive to
DST. Explain in more detail what date -v does when mixed with DST.

Previous code suggested broken by: wollman


# a625bfec 04-Apr-2000 Brian Somers <brian@FreeBSD.org>

Always give mktime a timeval with tm_isdst set to -1, otherwise
things get a bit out-of-phase when we step backwards 1 hour from
between 0:00 and 1:00 on the first of the month following the
transition into Summer time. This is probably actually a bug
in mktime().

PR: 10963

If mktime() fails and 68 < year < 138, assume that the reason is
because of Summer time and adjust up or down according to our
adjusting context by one hour. This assumes that all DSTs are
multiples of 1 hour.

PR: 6223, 17750


# 3b006d8e 18-Feb-2000 Alfred Perlstein <alfred@FreeBSD.org>

Re-add "May" to the list of dates supported.

Approved by: jkh


# 2a456239 27-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


# 426e9c1d 25-Apr-1999 Warner Losh <imp@FreeBSD.org>

First set of fixes to keep egcs happy. These include {} around single
statement if blocks[*] when the else could be ambiguous, not defaulting
to int type and removal of some unused variables.

[*] This is explicitly allowed by style(9) when the single statement
spans more than one line.

Reviewed by: obrien, chuckr


# 269dfbee 09-Mar-1999 Brian Somers <brian@FreeBSD.org>

Support seconds with -v.
PR: 6308
Submitted by: Max Euston <meuston@jmrodgers.com>


# cbf6f7d3 06-May-1998 Philippe Charnier <charnier@FreeBSD.org>

Correct use of .Nm and other cosmetics. Add rcsid. Remove unused #inc.


# c39934ea 20-Dec-1997 Brian Somers <brian@FreeBSD.org>

Add (BSD) copyright headers.


# 698f86e4 09-Aug-1997 Brian Somers <brian@FreeBSD.org>

Change [-DMHW [+|-]val] to [-v [+|-]val[ymwdHM]]
Support Hours & Minutes
Add -Wall to Makefile


# 7ca215a6 03-Aug-1997 Brian Somers <brian@FreeBSD.org>

Add [-DWMY] flags for date adjustment.
Discussed with: freebsd-hackers