[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] timezone change



On Thu, Mar 30, 2000 at 04:55:05PM +0300, Martin-Éric Racine wrote:
> > reads the time from the RTC.  In UTC clock mode it corrects
> > the RTC time to calculate localtime, in localtime clock mode
> > it corrects the RTC to calculate UTC.  
> 
> Corrects, as in changes the RTC time?  
> 
> If you mean that it offsets its time in regards to the RTC (or
> better yet, considers the RTC as residing in the user's TZ - as
> it should), that's different.

The kernel just adds offsets.  It only changes the RTC when told so (by
the time-setting functions).

> > The reason is simple: The kernel may or may not know by how much UTC and
> > local time differ /now/ but it has no idea about the offset that was in
> > use when creating the timestamp. 
> 
> Nor should it need to know.  It was created on date:time of an
> unspecified zone, just like GEMDOS.

And that leads to ambiguous and also to illegal timestamps that the kernel
and the user has to grok with.

> > If a DST change has taken place recently, how could the daemon
> > know if it has already reported the change to the RTC?  
> 
> No application should touch the RTC without human intervention.

But a daemon is supposed to run without user-interaction.  A daemon could
not change your clock automatically and you are forced to do that by hand.
You were the one that complained about that.

Guido
-- 
http://stud.uni-sb.de/~gufl0000/
Send your spam to president@whitehouse.gov and your replies to
mailto:guido at freemint dot de