summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2006-11-15 17:05:16 +0000
committerPascal Rigaux <pixel@mandriva.com>2006-11-15 17:05:16 +0000
commit75bdfdd4a5f911a18b9fd0ec60c15a310472a9d2 (patch)
tree9919adc8d229cf62d751bed4fbb99a1003201c37
parent3b444951a1e0efac6d703fb0fe97fc8d826a8ddc (diff)
downloadurpmi-75bdfdd4a5f911a18b9fd0ec60c15a310472a9d2.tar
urpmi-75bdfdd4a5f911a18b9fd0ec60c15a310472a9d2.tar.gz
urpmi-75bdfdd4a5f911a18b9fd0ec60c15a310472a9d2.tar.bz2
urpmi-75bdfdd4a5f911a18b9fd0ec60c15a310472a9d2.tar.xz
urpmi-75bdfdd4a5f911a18b9fd0ec60c15a310472a9d2.zip
cleanup using _parse_synthesis and _parse_hdlist return value
-rw-r--r--urpm.pm15
1 files changed, 7 insertions, 8 deletions
diff --git a/urpm.pm b/urpm.pm
index cc489598..7f4ee368 100644
--- a/urpm.pm
+++ b/urpm.pm
@@ -1129,17 +1129,16 @@ sub _update_media__virtual {
delete $medium->{modified};
$urpm->{md5sum_modified} = 1;
if ($medium->{synthesis}) {
- _parse_synthesis($urpm, $medium, $with_hdlist_dir);
- $medium->{synthesis} = 1;
- if (!is_valid_medium($medium)) {
- _parse_hdlist($urpm, $medium, $with_hdlist_dir);
+ if (_parse_synthesis($urpm, $medium, $with_hdlist_dir)) {
+ $medium->{synthesis} = 1;
+ $urpm->{modified} = 1;
+ } elsif (_parse_hdlist($urpm, $medium, $with_hdlist_dir)) {
delete $medium->{synthesis};
}
} else {
- _parse_hdlist($urpm, $medium, $with_hdlist_dir);
- delete $medium->{synthesis};
- if (!is_valid_medium($medium)) {
- _parse_synthesis($urpm, $medium, $with_hdlist_dir);
+ if (_parse_hdlist($urpm, $medium, $with_hdlist_dir)) {
+ delete $medium->{synthesis};
+ } elsif (_parse_synthesis($urpm, $medium, $with_hdlist_dir)) {
$medium->{synthesis} = 1;
}
}