History log of /freebsd/bin/date/vary.c (Results 1 – 25 of 33)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: release/14.0.0
# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

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


# 4ef3964b 04-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 03-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: 4238ce6f0c6df33ce677ae298

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)

show more ...


Revision tags: release/13.2.0, release/12.4.0, release/13.1.0, release/12.3.0, release/13.0.0, release/12.2.0, release/11.4.0, release/12.1.0, release/11.3.0, release/12.0.0, release/11.2.0, release/10.4.0, release/11.1.0, release/11.0.1, release/11.0.0, release/10.3.0, release/10.2.0, release/10.1.0, release/9.3.0, release/10.0.0, release/9.2.0, release/8.4.0, release/9.1.0, release/8.3.0_cvs, release/8.3.0, release/9.0.0, release/7.4.0_cvs, release/8.2.0_cvs, release/7.4.0, release/8.2.0, release/8.1.0_cvs, release/8.1.0, release/7.3.0_cvs, release/7.3.0, release/8.0.0_cvs, release/8.0.0, release/7.2.0_cvs, release/7.2.0, release/7.1.0_cvs, release/7.1.0, release/6.4.0_cvs, release/6.4.0, release/7.0.0_cvs, release/7.0.0, release/6.3.0_cvs, release/6.3.0, release/6.2.0_cvs, release/6.2.0, release/5.5.0_cvs, release/5.5.0, release/6.1.0_cvs, release/6.1.0, release/6.0.0_cvs, release/6.0.0, release/5.4.0_cvs, release/5.4.0, release/4.11.0_cvs, release/4.11.0, release/5.3.0_cvs, release/5.3.0
# 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 fro

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

show more ...


Revision tags: release/4.10.0_cvs, release/4.10.0, release/5.2.1_cvs, release/5.2.1, release/5.2.0_cvs, release/5.2.0, release/4.9.0_cvs, release/4.9.0, release/5.1.0_cvs, release/5.1.0, release/4.8.0_cvs, release/4.8.0, release/5.0.0_cvs, release/5.0.0, release/4.7.0_cvs, release/4.6.2_cvs, release/4.6.2, release/4.6.1, release/4.6.0_cvs
# 5eb43ac2 30-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.


Revision tags: release/4.5.0_cvs, release/4.4.0_cvs, release/4.3.0_cvs, release/4.3.0
# 6e4cd31d 01-Dec-2000 Brian Somers <brian@FreeBSD.org>

Exit if malloc() returns NULL

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


Revision tags: release/4.2.0, release/4.1.1_cvs, release/4.1.0, release/3.5.0_cvs
# 7ecff35b 24-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 05-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
transiti

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

show more ...


Revision tags: release/4.0.0_cvs
# 3b006d8e 19-Feb-2000 Alfred Perlstein <alfred@FreeBSD.org>

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

Approved by: jkh


Revision tags: release/3.4.0_cvs, release/3.3.0_cvs
# 2a456239 28-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


Revision tags: release/3.2.0
# 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.

[*] T

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

show more ...


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

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


Revision tags: release/3.1.0, release/3.0.0, release/2.2.8, release/2.2.7
# cbf6f7d3 06-May-1998 Philippe Charnier <charnier@FreeBSD.org>

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


Revision tags: release/2.2.6
# c39934ea 21-Dec-1997 Brian Somers <brian@FreeBSD.org>

Add (BSD) copyright headers.


Revision tags: release/2.2.5_cvs
# 698f86e4 10-Aug-1997 Brian Somers <brian@FreeBSD.org>

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


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

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


Revision tags: release/13.2.0, release/12.4.0, release/13.1.0, release/12.3.0, release/13.0.0, release/12.2.0, release/11.4.0, release/12.1.0, release/11.3.0, release/12.0.0, release/11.2.0, release/10.4.0, release/11.1.0, release/11.0.1, release/11.0.0, release/10.3.0, release/10.2.0, release/10.1.0, release/9.3.0, release/10.0.0, release/9.2.0, release/8.4.0, release/9.1.0, release/8.3.0_cvs, release/8.3.0, release/9.0.0, release/7.4.0_cvs, release/8.2.0_cvs, release/7.4.0, release/8.2.0, release/8.1.0_cvs, release/8.1.0, release/7.3.0_cvs, release/7.3.0, release/8.0.0_cvs, release/8.0.0, release/7.2.0_cvs, release/7.2.0, release/7.1.0_cvs, release/7.1.0, release/6.4.0_cvs, release/6.4.0, release/7.0.0_cvs, release/7.0.0, release/6.3.0_cvs, release/6.3.0, release/6.2.0_cvs, release/6.2.0, release/5.5.0_cvs, release/5.5.0, release/6.1.0_cvs, release/6.1.0, release/6.0.0_cvs, release/6.0.0, release/5.4.0_cvs, release/5.4.0, release/4.11.0_cvs, release/4.11.0, release/5.3.0_cvs, release/5.3.0
# 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 fro

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

show more ...


Revision tags: release/4.10.0_cvs, release/4.10.0, release/5.2.1_cvs, release/5.2.1, release/5.2.0_cvs, release/5.2.0, release/4.9.0_cvs, release/4.9.0, release/5.1.0_cvs, release/5.1.0, release/4.8.0_cvs, release/4.8.0, release/5.0.0_cvs, release/5.0.0, release/4.7.0_cvs, release/4.6.2_cvs, release/4.6.2, release/4.6.1, release/4.6.0_cvs
# 5eb43ac2 30-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.


Revision tags: release/4.5.0_cvs, release/4.4.0_cvs, release/4.3.0_cvs, release/4.3.0
# 6e4cd31d 01-Dec-2000 Brian Somers <brian@FreeBSD.org>

Exit if malloc() returns NULL

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


Revision tags: release/4.2.0, release/4.1.1_cvs, release/4.1.0, release/3.5.0_cvs
# 7ecff35b 24-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 05-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
transiti

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

show more ...


12