diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2004-07-02 04:15:08 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2004-07-02 04:15:08 +0000 |
commit | af3d0e0c117cb0bfc604f119849681700ad96a8a (patch) | |
tree | afedac054c55fce9d1cd47c26b28fe4b96eccc34 | |
parent | e4a01c5567ea5ca4cf390aee16a07e624ee57c43 (diff) | |
download | drakx-backup-do-not-use-af3d0e0c117cb0bfc604f119849681700ad96a8a.tar drakx-backup-do-not-use-af3d0e0c117cb0bfc604f119849681700ad96a8a.tar.gz drakx-backup-do-not-use-af3d0e0c117cb0bfc604f119849681700ad96a8a.tar.bz2 drakx-backup-do-not-use-af3d0e0c117cb0bfc604f119849681700ad96a8a.tar.xz drakx-backup-do-not-use-af3d0e0c117cb0bfc604f119849681700ad96a8a.zip |
(lang2move_clp_name): if $dir is a symlink, this symlink is broken at that moment, so test "-d $dir" after testing "-l $dir"
-rw-r--r-- | move/move.pm | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/move/move.pm b/move/move.pm index 5c3f9a94b..4f62cf514 100644 --- a/move/move.pm +++ b/move/move.pm @@ -106,8 +106,7 @@ sub setup_userconf { sub lang2move_clp_name { my ($lang) = @_; my $dir = '/usr/share/locale/' . lang::l2locale($lang); - -d $dir or return 'ERROR'; - my $link = readlink($dir) or return; + my $link = readlink($dir) or return -d $dir ? '' : 'ERROR'; my ($name) = $link =~ m!image_(i18n_.*?)/! or log::l("ERROR: bad link $link for $dir"), return 'ERROR'; $name; } |