diff options
author | Ulrich Drepper <drepper@redhat.com> | 1996-12-16 01:40:21 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 1996-12-16 01:40:21 +0000 |
commit | 860d3729868a749f782f6ad5dae1138cb239c4d3 (patch) | |
tree | 3722e55d8a4059529325df0e6c5ffbd168adbd88 /time/tzset.c | |
parent | 68dbb3a69e78e24a778c6602c8cc91d715839d08 (diff) | |
download | glibc-860d3729868a749f782f6ad5dae1138cb239c4d3.tar.gz glibc-860d3729868a749f782f6ad5dae1138cb239c4d3.tar.xz glibc-860d3729868a749f782f6ad5dae1138cb239c4d3.zip |
update from main archive 961215 cvs/libc-961216
Mon Dec 16 02:15:42 1996 Ulrich Drepper <drepper@cygnus.com> Make sure tzset() sets always tzname[]. * time/tzfile.c: De-ANSI-declfy. (find_transition): New function. Set tzname according to given time. (__tzread_file): Use find_transition to set tzname. (__tzfile_compute): Use find_transition instead of doing the work self. * time/tzset.c (tzset): Set tzname[] directly only if !__use_tzfile. Sun Dec 15 16:52:34 1996 Ulrich Drepper <drepper@cygnus.com> * login/utmp-file.c (pututline_file): Open file if closed. Reported by Roma Ekzhanov <ekzhanov@paragraph.com>. Use fcntl instead of flock. Sun Dec 15 14:20:51 1996 Ulrich Drepper <drepper@cygnus.com> * manual/time.texi: Update documentation of strftime function.
Diffstat (limited to 'time/tzset.c')
-rw-r--r-- | time/tzset.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/time/tzset.c b/time/tzset.c index 6a9ebe1f82..bbd562db6a 100644 --- a/time/tzset.c +++ b/time/tzset.c @@ -514,9 +514,12 @@ tzset (void) __tzset (); - /* Set `tzname'. */ - __tzname[0] = (char *) tz_rules[0].name; - __tzname[1] = (char *) tz_rules[1].name; + if (!__use_tzfile) + { + /* Set `tzname'. */ + __tzname[0] = (char *) tz_rules[0].name; + __tzname[1] = (char *) tz_rules[1].name; + } __libc_lock_unlock (__tzset_lock); } |