summaryrefslogtreecommitdiffstats
path: root/perl-install/timezone.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/timezone.pm')
-rw-r--r--perl-install/timezone.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/perl-install/timezone.pm b/perl-install/timezone.pm
index 98a33c368..ec252c603 100644
--- a/perl-install/timezone.pm
+++ b/perl-install/timezone.pm
@@ -64,8 +64,8 @@ sub write {
set_ntp_server($t->{ntp});
my $tz_prefix = get_timezone_prefix();
- unlink "$::prefix/etc/localtime" or log::l("unlinking $! failed");
- symlink ($tz_prefix . '/' . $t->{timezone}, "$::prefix/etc/localtime") or log::l("linking /etc/localtime failed");
+ eval { symlinkf($tz_prefix . '/' . $t->{timezone}, "$::prefix/etc/localtime") };
+ $@ and log::l("installing /etc/localtime failed");
setVarsInSh("$::prefix/etc/sysconfig/clock", {
ZONE => $t->{timezone},
UTC => bool2text($t->{UTC}),