]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
ctime.3: ctime_r() and localtime_r() need not set 'timezone' and 'daylight'
authorMichael Kerrisk <mtk.manpages@gmail.com>
Wed, 22 Oct 2008 06:14:15 +0000 (01:14 -0500)
committerMichael Kerrisk <mtk.manpages@gmail.com>
Wed, 29 Oct 2008 19:54:13 +0000 (14:54 -0500)
The man page already noted that these functions need not set
'tzname', but things could be clearer: it tzset() is not called,
then the other two variables also are not set.

Also, clarify that ctime() does set 'timezone' and 'daylight'.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
man3/ctime.3

index ddcc656f21f3291a7961502be90e9e6e147bb0da..b30cd404e989a6d677da30adf815fd8196eaef30 100644 (file)
@@ -161,7 +161,8 @@ The abbreviations for the months are "Jan",
 The return value points to a statically allocated string which
 might be overwritten by subsequent calls to any of the date and time
 functions.
-The function also sets the external variable \fItzname\fP (see
+The function also sets the external
+variables \fItzname\fP, \fItimezone\fP, and \fIdaylight\fP (see
 .BR tzset (3))
 with information about the current timezone.
 The reentrant version
@@ -170,7 +171,7 @@ does the same, but stores the
 string in a user-supplied buffer
 which should have room for at least 26 bytes.
 It need not
-set \fItzname\fP.
+set \fItzname\fP, \fItimezone\fP, and \fIdaylight\fP.
 .PP
 The
 .BR gmtime ()
@@ -203,7 +204,7 @@ The
 .BR localtime_r ()
 function does the same, but stores the data in a
 user-supplied struct.
-It need not set \fItzname\fP.
+It need not set \fItzname\fP, \fItimezone\fP, and \fIdaylight\fP.
 .PP
 The
 .BR asctime ()