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

Bug#360383: libc6: tzconfig doesn't check if /etc/localtime exists



Package: libc6
Version: 2.3.6-4
Severity: wishlist


Helping person on #debian, tzconfig showed correct timezone.

On investigation it appears his /etc/localtime link was missing, and
so tzconfig was incorrectly suggesting the tz settings were correct.

Suggest that tzconfig check that /etc/localtime exists before offering
the option to bail out without resetting the link if it is missing.

This will work...

 diff /usr/sbin/tzconfig /root/tzconfig.new
 47c47
 < if [ -f /etc/timezone ]; then
 ---
 > if [ -f /etc/timezone && -L /etc/localtime ]; then
 
.... but only if /etc/localtime should always exist?

This problem was probably caused by the user switching the system clock
from using localtime, to a system clock set to using UTC 
(explained in man tzconfig).

Need to check the patch works for those misguided people whose clock is
set to localtime. Looks simple enough to me, but I haven't tested it
beyond it avoids the problem experienced.

-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.15.2
Locale: LANG=en_GB, LC_CTYPE=en_GB (charmap=ISO-8859-1)

-- no debconf information



Reply to: