summaryrefslogtreecommitdiffstats
path: root/urpm.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2006-11-09 21:11:03 +0000
committerPascal Rigaux <pixel@mandriva.com>2006-11-09 21:11:03 +0000
commiteaa935f2f35dc566d7026165dd62dbf9cd2539a3 (patch)
tree1a1064460a4d632772c7c6659a8e38f369b2fe50 /urpm.pm
parentf0345dc2b5e47697325162c256d90b9dc6e0f372 (diff)
downloadurpmi-eaa935f2f35dc566d7026165dd62dbf9cd2539a3.tar
urpmi-eaa935f2f35dc566d7026165dd62dbf9cd2539a3.tar.gz
urpmi-eaa935f2f35dc566d7026165dd62dbf9cd2539a3.tar.bz2
urpmi-eaa935f2f35dc566d7026165dd62dbf9cd2539a3.tar.xz
urpmi-eaa935f2f35dc566d7026165dd62dbf9cd2539a3.zip
use cat_
Diffstat (limited to 'urpm.pm')
-rw-r--r--urpm.pm7
1 files changed, 1 insertions, 6 deletions
diff --git a/urpm.pm b/urpm.pm
index 01f389a5..a1ab7295 100644
--- a/urpm.pm
+++ b/urpm.pm
@@ -450,15 +450,10 @@ sub configure {
if ($options{parallel}) {
my ($parallel_options, $parallel_handler);
#- read parallel configuration
- local $_;
- my $parallel = $urpm->open_safe("<", "/etc/urpmi/parallel.cfg");
- if ($parallel) {
- while (<$parallel>) {
+ foreach (cat_("/etc/urpmi/parallel.cfg")) {
chomp; s/#.*$//; s/^\s*//; s/\s*$//;
/\s*([^:]*):(.*)/ or $urpm->{error}(N("unable to parse \"%s\" in file [%s]", $_, "/etc/urpmi/parallel.cfg")), next;
$1 eq $options{parallel} and $parallel_options = ($parallel_options && "\n") . $2;
- }
- close $parallel;
}
#- if a configuration option has been found, use it; else fatal error.
if ($parallel_options) {