Date: Sun, 28 Oct 2018 02:58:23 +0000 (UTC) From: Warner Losh <imp@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r339833 - head/lib/libc/sys Message-ID: <201810280258.w9S2wNtD027636@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: imp Date: Sun Oct 28 02:58:22 2018 New Revision: 339833 URL: https://svnweb.freebsd.org/changeset/base/339833 Log: Note that the kenrel doesn't keep track daylight savings time, nor timezone offset. These values are generally zero. While one still theoreticall could set these values, that's almost never done. Users wishing to have an offset between the time of day clock hardware and UTC use adjkerntz(8) instead. localtime(3) should be used to find these values for the current timezone. Modified: head/lib/libc/sys/gettimeofday.2 Modified: head/lib/libc/sys/gettimeofday.2 ============================================================================== --- head/lib/libc/sys/gettimeofday.2 Sun Oct 28 02:58:15 2018 (r339832) +++ head/lib/libc/sys/gettimeofday.2 Sun Oct 28 02:58:22 2018 (r339833) @@ -89,6 +89,11 @@ structure indicates the local time zone and a flag that, if nonzero, indicates that Daylight Saving time applies locally during the appropriate part of the year. +The kernel generally does not track these values and they +are usually returned as zero. +Use +.Xr localtime 3 +to find the offset for the currently active timezone. .Pp Only the super-user may set the time of day or time zone. If the system is running at securelevel >= 2 (see
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201810280258.w9S2wNtD027636>