diff options
author | Thierry Vignaud <tv@mageia.org> | 2012-06-08 18:52:05 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mageia.org> | 2012-06-08 18:52:05 +0000 |
commit | def552f8ef28f613dc0e6daa2b19d2cab0bdcc09 (patch) | |
tree | 51251217a3da47970c37e20b1cb6c53b3cec6a29 /urpm | |
parent | d74b89cc3616de79b5a5301e26c5386df79a637e (diff) | |
download | urpmi-def552f8ef28f613dc0e6daa2b19d2cab0bdcc09.tar urpmi-def552f8ef28f613dc0e6daa2b19d2cab0bdcc09.tar.gz urpmi-def552f8ef28f613dc0e6daa2b19d2cab0bdcc09.tar.bz2 urpmi-def552f8ef28f613dc0e6daa2b19d2cab0bdcc09.tar.xz urpmi-def552f8ef28f613dc0e6daa2b19d2cab0bdcc09.zip |
(_install_src) simplify
Diffstat (limited to 'urpm')
-rw-r--r-- | urpm/main_loop.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/urpm/main_loop.pm b/urpm/main_loop.pm index 8d27ab88..a0d811a6 100644 --- a/urpm/main_loop.pm +++ b/urpm/main_loop.pm @@ -133,7 +133,8 @@ sub _install_src { my ($urpm, $transaction_sources_install, $transaction_sources) = @_; if (my @l = grep { /\.src\.rpm$/ } values %$transaction_sources_install, values %$transaction_sources) { my $rpm_opt = $options{verbose} >= 0 ? 'vh' : ''; - system("rpm", "-i$rpm_opt", @l, ($urpm->{root} ? ("--root", $urpm->{root}) : @{[]})); + push @l, "--root", $urpm->{root} if $urpm->{root}; + system("rpm", "-i$rpm_opt", @l); #- Warning : the following message is parsed in urpm::parallel_* if ($?) { $urpm->{print}(N("Installation failed")); |