After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 19197 - clock applet should periodically recheck the timezone
clock applet should periodically recheck the timezone
Status: RESOLVED NOTGNOME
Product: gnome-panel
Classification: Other
Component: clock
2.0.x
Other Linux
: Normal minor
: ---
Assigned To: Panel Maintainers
Panel Maintainers
: 95011 130913 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2000-07-30 16:40 UTC by marillat.christian
Modified: 2015-03-24 13:00 UTC
See Also:
GNOME target: ---
GNOME version: 2.1/2.2


Attachments
Patch file for the Clock - Timezone problem. (628 bytes, patch)
2004-07-29 07:22 UTC, Anoopkm
none Details | Review

Description marillat.christian 2001-01-27 21:59:09 UTC
Package: gnome-applets
Version: 1.2.0
Severity: normal

>Originator: 	 Christian Marillat
>Organization:
net
>Synopsis: another_clock_applet should periodically recheck the timezone
>Class: sw-bug
>Gnome-Libs-Release: gnome-libs-1.2.4
>Environment:
    	 Linux 2.2.14
System: Linux falcon.wanadoo.fr 2.2.16 #1 jeu jun 8 12:24:33 CEST 2000 i686 unknown
Architecture: i686

Distribution: Debian Version: 2.2

>Description:

[This is a Debian bug report #61611, reported by Thomas Bushnell BSG
<tb@MIT.EDU>]

As I write this bug report, I'm in an airplane flying from Boston to Los
Angeles.  I just updated the timezone with tzconfig, from US/Eastern to
US/Pacific.  The ate' utility now reports the new timezone.  However,
another_clock_applet, already running on my desktop, has not rechecked
the timezone, so it still displays the time as it is back in Boston.

When the timezone changes, the system should take note.  For most programs
this isn't as necessary, but gnome is supposed to not require me to log
out and back in when my configuration changes, Debian is supposed to be
"spiffy" about such dynamic updates, and panel applets can be expected to
run a long time.

Christian




------- Bug moved to this database by debbugs-export@bugzilla.gnome.org 2001-01-27 16:59 -------
This bug was previously known as bug 19197 at http://bugs.gnome.org/
http://bugs.gnome.org/show_bug.cgi?id=19197
Originally filed under the gnome-applets product and general component.

The original reporter (marillat.christian@wanadoo.fr) of this bug does not have an account here.
Reassigning to the exporter, debbugs-export@bugzilla.gnome.org.
Reassigning to the default owner of the component, gnome-applets-maint@bugzilla.gnome.org.

Comment 1 Telsa Gwynne 2001-05-31 11:08:14 UTC
All the clocks should do this, I think. The only way to get
them to notice is to start a new clock. I used to have a very
funny example screenshot of this with two clocks next to each
other showing different times: one was running, then I reset
the clock, then added the second one. Two different answers.
Ugh :)

Comment 2 Kjartan Maraas 2002-02-02 10:10:14 UTC
Should be fixed for 2.0 I guess.
Comment 3 Luis Villa 2002-02-28 13:48:28 UTC
Minor as this is pretty much an edge case.
Comment 4 Dave Bordoley [Not Reading Bug Mail] 2002-04-11 11:43:09 UTC
going to move to gnome-panel. The regular clock applet should do this
too. It kind of does, but isn't dependable enough. I tried this using
redhat's time config tool.
Comment 5 Vincent Untz 2002-10-06 20:37:23 UTC
*** Bug 95011 has been marked as a duplicate of this bug. ***
Comment 6 Kjartan Maraas 2002-10-28 18:00:56 UTC
Has anyone tested this in a later release?
Comment 7 Christian Marillat 2002-10-28 18:10:53 UTC
This bug is still here in 2.0.10
Comment 8 David Kennedy 2003-03-26 00:34:56 UTC
Still in 2.2
Comment 9 Ben FrantzDale 2003-05-23 07:08:59 UTC
Still here in 2.2.1.
I've been confused about this for a while and finally figured out that
this is the behavior. I had gotten quite confused about the
time-config tool's behavior. When I switched timezones I'd use
time-config to change the timezone and then I'd have to adjust the
clock time as well. But to get the time on the panel applet right I'd
have to set the system clock wrong. Then the next day when I logged
out and back in, the clock would be wrong again.
Comment 10 Vincent Untz 2004-01-08 16:49:45 UTC
*** Bug 130913 has been marked as a duplicate of this bug. ***
Comment 11 Mark McLoughlin 2004-02-27 16:16:46 UTC
From http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=91804:

I think this is essentially a C library limitation, it does not 
reload the timezone info until you restart the process.

(clock is not a separate process, just part of the panel; "killall
gnome-panel" should get you a new timezone clock)

We can probably come up with some hack to fix it.
Comment 12 Anoopkm 2004-07-29 07:22:02 UTC
Created attachment 30029 [details] [review]
Patch file for the Clock - Timezone problem.

    You should not normally need to set `TZ'.  If the system is
 configured properly, the default time zone will be correct.  You might
 set `TZ' if you are using a computer over a network from a different
 time zone, and would like times reported to you in the time zone local
 to you, rather than what is local to the computer.

   If the `TZ' environment variable does not have a value, the
 operation chooses a time zone by default.  In the GNU C library, the
 default time zone is like the specification `TZ=:/etc/localtime' (or
 `TZ=:/usr/local/etc/localtime', depending on how GNU C library was
 configured

So when the time zone is changed we should have to change the TZ Environment
variable to /etc/localtime. By derault /etc/localtime will be null. After
changing the timezone, All informations will be loaded to here. So
/etc/localtime will now contain the new timezone information.

But in localtime.c, it returns the localtime according to the timezone, only if
the TZ pointer changes. TZ pointer never changes its location (/etc/localtime),
only the content of /etc/localtime is changing.

initially changing the TZ to null using 
setenv ("TZ","",1);
then calling the localtime.
after it sets to original location using
setenv ("TZ","/etc/localtime",1);
then again calling the localtime. 
Now it returs exact value.
Comment 13 Ben FrantzDale 2004-07-30 07:12:28 UTC
> You should not normally need to set `TZ'.
On a laptop, I like to set the time zone to be correct wherever I go. (Or do I
misunderstand you.)
Comment 14 Mark McLoughlin 2004-09-29 10:30:40 UTC
Okay, recent changes in glibc is going to fix this. Changes to /etc/localtime
will be noticed and the file will be re-read. I think the fixes will be in glibc
2.3.4.

See:

  https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=133481

Closing as NOTGNOME.