summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2003-11-20 23:03:38 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2003-11-20 23:03:38 +0000
commit8b321d773f9de7f97d056650aff2e8e467e02572 (patch)
tree2dd8754a073d2e6721a28e9561b2e7782baa0d37
parent88c351a0e7e4d0b3474774e6dbb69ee2a0481a9c (diff)
downloaddrakx-8b321d773f9de7f97d056650aff2e8e467e02572.tar
drakx-8b321d773f9de7f97d056650aff2e8e467e02572.tar.gz
drakx-8b321d773f9de7f97d056650aff2e8e467e02572.tar.bz2
drakx-8b321d773f9de7f97d056650aff2e8e467e02572.tar.xz
drakx-8b321d773f9de7f97d056650aff2e8e467e02572.zip
kill duplicated code once again
-rw-r--r--move/move.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/move/move.pm b/move/move.pm
index 80741429f..f21addfb2 100644
--- a/move/move.pm
+++ b/move/move.pm
@@ -16,6 +16,7 @@ my @ALLOWED_LANGS = qw(en_US fr es it de);
my ($using_existing_user_config, $using_existing_host_config);
my $key_sysconf = '/home/.sysconf';
my $virtual_key_part;
+my $key_mountopts = 'umask=077,uid=501,gid=501,shortname=mixed';
sub symlinkf_short {
my ($dest, $file) = @_;
@@ -50,7 +51,7 @@ sub handle_virtual_key {
require devices;
my $loop = devices::find_free_loop();
run_program::run('losetup', $loop, "$dir$file");
- run_program::run('mount', $loop, '/home', '-o', 'umask=077,uid=501,gid=501,shortname=mixed');
+ run_program::run('mount', $loop, '/home', '-o', $key_mountopts);
$virtual_key_part = { device => $loop, mntpoint => '/home', type => 0xc, isMounted => 1 };
}
}
@@ -194,7 +195,7 @@ sub key_parts {
my @keys = grep { $_->{usb_media_type} && index($_->{usb_media_type}, 'Mass Storage|') == 0 && $_->{media_type} eq 'hd' } @{$o->{all_hds}{hds}};
map_index {
$_->{mntpoint} = $::i ? "/mnt/key$::i" : '/home';
- $_->{options} = 'umask=077,uid=501,gid=501,shortname=mixed';
+ $_->{options} = $key_mountopts;
$_;
} fsedit::get_fstab(@keys);
}