From 227a7b4f441a4d174b8862a7ab43b469f0ab7f64 Mon Sep 17 00:00:00 2001 From: Pascal Terjan Date: Tue, 3 Oct 2017 19:13:31 +0100 Subject: Do not read all rpms in check_media, synthesis can be trusted --- iurt | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/iurt b/iurt index 74bfb29..268af74 100755 --- a/iurt +++ b/iurt @@ -1106,24 +1106,6 @@ sub check_pid { sub check_media { my ($run, $cache, $config, $srpm_version, $provides, $pack_provide, $maint) = @_; -# We could rely only on parsing the synthesis, hoping that they are correct, however this scan is very fast, so... - if (!$run->{build_all}) { - foreach my $subdir (@{$config->{all_media}{$run->{media}}}) { - my $rpms_dir = "$config->{repository}/$run->{distro}/$run->{my_arch}/media/$run->{media}/$subdir/"; - plog("checking current packages in $rpms_dir"); - opendir my $rpmdir, $rpms_dir or die "Could not open $rpms_dir: $!"; - my $urpmi = $run->{urpmi}; - foreach my $rpm (readdir $rpmdir) { - my ($rarch, $srpm) = $urpmi->update_srpm($rpms_dir, $rpm); - $rarch or next; - $cache->{queue}{$srpm} = 1; - $run{status}{$srpm} = 'ok'; - check_version($run, $srpm, $srpm_version); - } - closedir $rpmdir; - } - } - foreach my $m (keys %{$config->{all_media}}) { foreach my $subdir (@{$config->{all_media}{$m}}) { my $synthesis_file = "$config->{repository}/$run->{distro}/$run->{my_arch}/media/$m/$subdir/media_info/synthesis.hdlist.cz"; -- cgit v1.2.1