Timezone classes

Nicolas Goutte nicolasg at snafu.de
Sat Sep 17 20:59:07 BST 2005


On Saturday 17 September 2005 20:27, Shaheed wrote:
> On Thursday 15 September 2005 19:06, Nicolas Goutte wrote:
> > On Thursday 15 September 2005 19:50, David Jarvie wrote:
> > (...)
> >
> > > KTimezones::local() doesn't allow for the possibility of /etc/localtime
> > > being a link to a file in /use/share/zoneinfo/ (or wherever). This is
> > > quite
> >
> > If I remember well, the problem about /etc/localtime being a link, had
> > been reported immediately in kde-commits (but apparently the code was not
> > changed).
>
> I don't understand either comment (from David or Nicolas). The code in
> question is trying to find the name of the file in /use/share/zoneinfo/ (or
> wherever) with the link or copy of the file that is in /etc/localtime.
>
> AFAICS, it should work in both the link or copy case (I am not able to test
> right now, but I thought I had done so).
>
> Does that make more sense? Maybe I need to make the comment there a bit
> more verbose...

As far as I understand the critic, the wish is to find that the file is a link 
and to use that link instead of guessing it with some MD5 handling.

Sure the current code should work but it is quite an overhead in such a case, 
as MD5-ing thousand of files uses much computing power. (Counting 
quickly&dirty the SuSE 9.0 on my system has 1611 files in the /usr/share/
zoneinfo and its subdirectories. However here it is not a link.)

>
> Thanks, Shaheed

Have a nice day!





More information about the kde-core-devel mailing list