summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-06-24 09:39:06 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-06-24 09:39:06 +0000
commit2097f0f18e1362d5e020cefbdbf304ca8754c076 (patch)
tree2bedb8deab8b652e901844982fe3eeb9aed93064
parent4888cad3851aa49beaeb544e012e1b169e79598a (diff)
downloadurpmi-2097f0f18e1362d5e020cefbdbf304ca8754c076.tar
urpmi-2097f0f18e1362d5e020cefbdbf304ca8754c076.tar.gz
urpmi-2097f0f18e1362d5e020cefbdbf304ca8754c076.tar.bz2
urpmi-2097f0f18e1362d5e020cefbdbf304ca8754c076.tar.xz
urpmi-2097f0f18e1362d5e020cefbdbf304ca8754c076.zip
Don't write a section for the global options if we don't need to
-rw-r--r--urpm/cfg.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/urpm/cfg.pm b/urpm/cfg.pm
index b6610c71..ec8f064a 100644
--- a/urpm/cfg.pm
+++ b/urpm/cfg.pm
@@ -134,6 +134,7 @@ sub dump_config ($$) {
if ($m) {
print $f quotespace($m), ' ', quotespace($config->{$m}{url}), " {\n";
} else {
+ next if !keys %{$config->{''}};
print $f "{\n";
}
for (sort grep { $_ ne 'url' } keys %{$config->{$m}}) {