[PATCH 3/4] Don't write out /etc/sysconfig/clock anymore (#859217).

Chris Lumens clumens at redhat.com
Thu Sep 20 20:56:35 UTC 2012


---
 pyanaconda/timezone.py                 | 8 --------
 tests/pyanaconda_test/timezone_test.py | 2 --
 2 files changed, 10 deletions(-)

diff --git a/pyanaconda/timezone.py b/pyanaconda/timezone.py
index 61cdd9a..0b7173d 100644
--- a/pyanaconda/timezone.py
+++ b/pyanaconda/timezone.py
@@ -69,14 +69,6 @@ def write_timezone_config(timezone, root):
                       (rooted_tz_file, oserr.strerror))
 
     try:
-        with open(os.path.normpath(root + "/etc/sysconfig/clock"), "w") as fobj:
-            fobj.write('ZONE="%s"\n' % timezone.timezone)
-    except IOError as ioerr:
-        msg = "Error while writing /etc/sysconfig/clock file: %s" % \
-                ioerr.strerror
-        raise TimezoneConfigError(msg)
-
-    try:
         fobj = open(os.path.normpath(root + "/etc/adjtime"), "r")
         lines = fobj.readlines()
         fobj.close()
diff --git a/tests/pyanaconda_test/timezone_test.py b/tests/pyanaconda_test/timezone_test.py
index 499989f..a53f292 100644
--- a/tests/pyanaconda_test/timezone_test.py
+++ b/tests/pyanaconda_test/timezone_test.py
@@ -51,8 +51,6 @@ class TimeZoneTest(mock.TestCase):
         f.close()
 
         tz.write()
-        example = 'ZONE="%s"\n' % ZONE
-        self.assertEqual(self.fs['/mnt/sysimage/etc/sysconfig/clock'], example)
         self.assertEqual(self.fs['/mnt/sysimage/etc/adjtime'], ADJTIME)
 
 
-- 
1.7.11.2



More information about the anaconda-patches mailing list