diff options
author | Thierry Vignaud <tvignaud@mandriva.org> | 2004-03-05 08:45:26 +0000 |
---|---|---|
committer | Thierry Vignaud <tvignaud@mandriva.org> | 2004-03-05 08:45:26 +0000 |
commit | 59ef53a2ef3dcf8e68e574d94508ad8b7bcdb377 (patch) | |
tree | f602ac0622a70f0136fe6e3ae627e242cf9fa113 | |
parent | fe969d2b1fe3a88e22de38ce85e5479fc684a45a (diff) | |
download | drakx-backup-do-not-use-59ef53a2ef3dcf8e68e574d94508ad8b7bcdb377.tar drakx-backup-do-not-use-59ef53a2ef3dcf8e68e574d94508ad8b7bcdb377.tar.gz drakx-backup-do-not-use-59ef53a2ef3dcf8e68e574d94508ad8b7bcdb377.tar.bz2 drakx-backup-do-not-use-59ef53a2ef3dcf8e68e574d94508ad8b7bcdb377.tar.xz drakx-backup-do-not-use-59ef53a2ef3dcf8e68e574d94508ad8b7bcdb377.zip |
(write_resolv_conf) only remove /etc/resolv.conf if it's really a link
(prevent no resolv.conf rewriting when it was empty eg b/c link was
dead)
-rw-r--r-- | perl-install/network/network.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/perl-install/network/network.pm b/perl-install/network/network.pm index cccd4767d..37d4e3e2c 100644 --- a/perl-install/network/network.pm +++ b/perl-install/network/network.pm @@ -121,7 +121,7 @@ sub write_resolv_conf { push @unknown, $_; } } - unlink $file; #- workaround situation when /etc/resolv.conf is an absolute link to /etc/ppp/resolv.conf or whatever + unlink $file if -l $file; #- workaround situation when /etc/resolv.conf is an absolute link to /etc/ppp/resolv.conf or whatever if (@{$new{search}} || @{$new{nameserver}}) { $prev{$_} = [ difference2($prev{$_} || [], $new{$_}) ] foreach keys %new; |