CVS commit: [netbsd-11] src/lib/libc/time

"Martin Husemann" <[email protected]>
Newsgroups gmane.os.netbsd.devel.cvs
Message-ID <[email protected]>
Module Name:	src
Committed By:	martin
Date:		Sat Jun 27 10:54:08 UTC 2026

Modified Files:
	src/lib/libc/time [netbsd-11]: strptime.c

Log Message:
Pull up following revision(s) (requested by wiz in ticket #318):

	lib/libc/time/strptime.c: revision 1.68

Fix day of week calculcation in strptime().

The bug was that the calculation used the raw year value without
adding the 1900 offset.

While here, switch to the current Wikipedia version of Gauss' algorithm,
like FreeBSD did, and simplify a loop, like FreeBSD did.


To generate a diff of this commit:
cvs rdiff -u -r1.67 -r1.67.4.1 src/lib/libc/time/strptime.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.