summary refs log tree commit diff
path: root/manual/time.texi
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1995-09-21 04:01:40 +0000
committerRoland McGrath <roland@gnu.org>1995-09-21 04:01:40 +0000
commit600927014b78e4247e36bbc554c188c7a3cca40e (patch)
treecf802f95fda74fadebc8683ac1b584b527f9fbaa /manual/time.texi
parentbf40c56f1a3f569780b99c8187aaa3f580de36d4 (diff)
downloadglibc-600927014b78e4247e36bbc554c188c7a3cca40e.tar.gz
glibc-600927014b78e4247e36bbc554c188c7a3cca40e.tar.xz
glibc-600927014b78e4247e36bbc554c188c7a3cca40e.zip
Wed Sep 20 18:02:03 1995 Roland McGrath <roland@churchy.gnu.ai.mit.edu>
	* locale/locale.c: Include errno.h.
	* locale/localedef.c: Likewise.

Tue Sep 19 00:02:06 1995  Roland McGrath  <roland@churchy.gnu.ai.mit.edu>

	* Makefile (distclean-1): Remove config.cache, config.log, config.h.
	(parent-mostlyclean): Remove all flavors of the parent library.

	* misc/mntent.c (getmntent): Skip multiple whitespace chars
	between fields.

	* hurd/hurdstartup.c (_hurd_startup): If RPC returns
	EXEC_STACK_ARGS flag, get args from stack.
	If args on stack but have info from RPC, relocate args on stack to make
	space for struct hurd_startup_data.

	* elf/dl-object.c: Include errno.h.
	* posix/execvp.c: Likewise.
	* dirent/scandir.c: Likewise.
	* sysdeps/posix/system.c: Likewise.
	* sysdeps/generic/setenv.c: Likewise.
	* stdlib/msort.c: Likewise.
	* stdio/memstream.c: Likewise.
	* stdio/fclose.c: Likewise.
	* stdio/getdelim.c: Likewise.
	* stdio/setvbuf.c: Likewise.
	* sysdeps/ieee754/ldexp.c: Likewise.
	* locale/locfile-parse.c: Likewise.

	* stdlib/lcong48_r.c: Don't check for null argument; let it fault.
	* stdlib/seed48_r.c: Likewise.
	* stdlib/srand48_r.c: Likewise.
	* stdlib/jrand48_r.c: Likewise.
	* stdlib/nrand48_r.c: Likewise.

	* misc/search.h: Many decls for hsearch functions.
Diffstat (limited to 'manual/time.texi')
-rw-r--r--manual/time.texi37
1 files changed, 21 insertions, 16 deletions
diff --git a/manual/time.texi b/manual/time.texi
index 767c318a42..3f8eee46a3 100644
--- a/manual/time.texi
+++ b/manual/time.texi
@@ -241,13 +241,15 @@ These facilities are declared in the header file @file{time.h}.
 @comment time.h
 @comment ANSI
 @deftp {Data Type} time_t
-This is the data type used to represent calendar time.  In the GNU C
-library and other POSIX-compliant implementations, @code{time_t} is
-equivalent to @code{long int}.  When interpreted as an absolute time
+This is the data type used to represent calendar time.
+When interpreted as an absolute time
 value, it represents the number of seconds elapsed since 00:00:00 on
 January 1, 1970, Coordinated Universal Time.  (This date is sometimes
-referred to as the @dfn{epoch}.)
+referred to as the @dfn{epoch}.)  POSIX requires that this count
+ignore leap seconds, but on some hosts this count includes leap seconds
+if you set @code{TZ} to certain values (@pxref{TZ Variable}).
 
+In the GNU C library, @code{time_t} is equivalent to @code{long int}.
 In other systems, @code{time_t} might be either an integer or
 floating-point type.
 @end deftp
@@ -257,7 +259,8 @@ floating-point type.
 @deftypefun double difftime (time_t @var{time1}, time_t @var{time0})
 The @code{difftime} function returns the number of seconds elapsed
 between time @var{time1} and time @var{time0}, as a value of type
-@code{double}.  
+@code{double}.  The difference ignores leap seconds unless leap
+second support is enabled.
 
 In the GNU system, you can simply subtract @code{time_t} values.  But on
 other systems, the @code{time_t} data type might use some other encoding
@@ -462,8 +465,8 @@ contains at least the following members, which can appear in any order:
 @table @code
 @item int tm_sec
 This is the number of seconds after the minute, normally in the range
-@code{0} to @code{59}.  (The actual upper limit is @code{61}, to allow
-for ``leap seconds''.)
+@code{0} to @code{59}.  (The actual upper limit is @code{60}, to allow
+for leap seconds if leap second support is available.)
 @cindex leap second
 
 @item int tm_min
@@ -508,7 +511,7 @@ also think of this as the ``number of seconds west'' of GMT.  The
 @code{tm_gmtoff} field is a GNU library extension.
 
 @item const char *tm_zone
-This field is the three-letter name for the time zone that was used to
+This field is the name for the time zone that was used to
 compute this broken-down time value.  It is a GNU library extension.
 @end table
 @end deftp
@@ -521,9 +524,9 @@ The @code{localtime} function converts the calendar time pointed to by
 user's specified time zone.
 
 The return value is a pointer to a static broken-down time structure, which
-might be overwritten by subsequent calls to any of the date and time
-functions.  (But no other library function overwrites the contents of this
-object.)
+might be overwritten by subsequent calls to @code{ctime}, @code{gmtime},
+or @code{localtime}.  (But no other library function overwrites the contents
+of this object.)
 
 Calling @code{localtime} has one other effect: it sets the variable
 @code{tzname} with information about the current time zone.  @xref{Time
@@ -590,7 +593,7 @@ The abbreviations for the months are: @samp{Jan}, @samp{Feb},
 @samp{Sep}, @samp{Oct}, @samp{Nov}, and @samp{Dec}.
 
 The return value points to a statically allocated string, which might be
-overwritten by subsequent calls to any of the date and time functions.
+overwritten by subsequent calls to @code{asctime} or @code{ctime}.
 (But no other library function overwrites the contents of this
 string.)
 @end deftypefun
@@ -870,7 +873,7 @@ community of volunteers and put in the public domain.
 @comment POSIX.1
 @deftypevar char * tzname [2]
 The array @code{tzname} contains two strings, which are the standard
-three-letter names of the pair of time zones (standard and daylight
+names of the pair of time zones (standard and daylight
 savings) that the user has selected.  @code{tzname[0]} is the name of
 the standard time zone (for example, @code{"EST"}), and @code{tzname[1]}
 is the name for the time zone when daylight savings time is in use (for
@@ -893,7 +896,7 @@ depend on the time zone.
 @end deftypefun
 
 The following variables are defined for compatibility with System V
-Unix.  These variables are set by calling @code{localtime}.
+Unix.  These variables are set by calling @code{tzset}.
 
 @comment time.h
 @comment SVID
@@ -906,8 +909,10 @@ seconds.  For example, in the U.S. Eastern time zone, the value is
 @comment time.h
 @comment SVID
 @deftypevar int daylight
-This variable has a nonzero value if the standard U.S. daylight savings
-time rules apply.
+This variable has a nonzero value if daylight savings time rules apply.
+A nonzero value does not necessarily mean that daylight savings time is
+now in effect; it means only that daylight savings time is sometimes in
+effect.
 @end deftypevar
 
 @node Time Functions Example