From 742223d1775b04904c9571e442fba79d5c992404 Mon Sep 17 00:00:00 2001 From: Rafael Garcia-Suarez Date: Tue, 14 Sep 2004 01:56:02 +0000 Subject: Don't print the urpmf results twice when using virtual media with hdlists. --- urpm.pm | 6 +++--- urpmf | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/urpm.pm b/urpm.pm index 332b0c86..b7090278 100644 --- a/urpm.pm +++ b/urpm.pm @@ -491,13 +491,13 @@ sub configure { "$path/$_->{with_hdlist}", callback => $options{callback}); } else { $urpm->{log}(N("examining hdlist file [%s]", "$path/$_->{with_hdlist}")); + #- we'll need a second pass + defined $second_pass or $second_pass = 1; ($_->{start}, $_->{end}) = $urpm->parse_hdlist( "$path/$_->{with_hdlist}", packing => 1, - callback => $options{callback}, + callback => $options{call_back_only_once} && $second_pass ? undef : $options{callback}, ); - #- we need a second pass now. - defined $second_pass or $second_pass = 1; } } else { $urpm->{error}(N("virtual medium \"%s\" is not local, medium ignored", $_->{name})); diff --git a/urpmf b/urpmf index 6327bca2..2a88ff90 100755 --- a/urpmf +++ b/urpmf @@ -138,6 +138,7 @@ $urpm->configure( synthesis => $synthesis, update => $update, callback => $callback, + call_back_only_once => 1, hdlist => $use_hdlist, ); $urpm->unlock_urpmi_db; -- cgit v1.2.1