diff options
author | Olivier Blin <oblin@mandriva.org> | 2004-08-13 04:41:05 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2004-08-13 04:41:05 +0000 |
commit | cfc21c9339ce1306651adf5184f9a39763d0e28f (patch) | |
tree | 472da272e9ffff1a1c373570afa67161a2eb9634 | |
parent | 89490a2dad02316682b601af9425ad4d7805ba71 (diff) | |
download | drakx-cfc21c9339ce1306651adf5184f9a39763d0e28f.tar drakx-cfc21c9339ce1306651adf5184f9a39763d0e28f.tar.gz drakx-cfc21c9339ce1306651adf5184f9a39763d0e28f.tar.bz2 drakx-cfc21c9339ce1306651adf5184f9a39763d0e28f.tar.xz drakx-cfc21c9339ce1306651adf5184f9a39763d0e28f.zip |
(device_name_to_entry) do devfs things where they should be done
-rwxr-xr-x | perl-install/standalone/drakupdate_fstab | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/perl-install/standalone/drakupdate_fstab b/perl-install/standalone/drakupdate_fstab index 9a34c317d..62950def6 100755 --- a/perl-install/standalone/drakupdate_fstab +++ b/perl-install/standalone/drakupdate_fstab @@ -65,6 +65,10 @@ sub device_name_to_entry { if ((my $devfs_prefix, $nb) = $name =~ m,(.*)/(?:cd|disc|part(\d+))$,) { $e = find { $_->{devfs_prefix} eq $devfs_prefix } @l; $e->{devfs_prefix} ||= $devfs_prefix; + $e->{devfs_device} = $e->{devfs_prefix} . '/part' . $nb; + if ($e->{devfs_device} eq $name) { + $e->{prefer_devfs_name} = 1; + } } else { if ($e = find { $name eq $_->{device} } @l) { $nb = ''; @@ -75,13 +79,10 @@ sub device_name_to_entry { } if ($nb) { - $e->{devfs_device} = $e->{devfs_prefix} . '/part' . $nb; $e->{device} = ($e->{prefix} || $e->{device}) . $nb; } $e ||= {}; - if ($e->{devfs_device} eq $name) { - $e->{prefer_devfs_name} = 1; - } else { + unless ($e->{devfs_device} eq $name) { $e->{device} = $name; #- keeping the exact name given (often is the devfs name) } $e->{media_type} = 'fd' if $name =~ /fd[01]/; |