[libconfig-model-dpkg-perl] 09/24: removed callback from cache_info_from_madison
dod at debian.org
dod at debian.org
Sun Apr 20 13:07:46 UTC 2014
This is an automated email from the git hooks/post-receive script.
dod pushed a commit to branch master
in repository libconfig-model-dpkg-perl.
commit 421806cf104baa0322e64a3f926c86babace56ad
Author: Dominique Dumont <dod at debian.org>
Date: Tue Apr 15 19:49:05 2014 +0200
removed callback from cache_info_from_madison
---
lib/Config/Model/Backend/Dpkg/Control.pm | 15 +--------------
lib/Config/Model/Dpkg/Dependency.pm | 4 +---
2 files changed, 2 insertions(+), 17 deletions(-)
diff --git a/lib/Config/Model/Backend/Dpkg/Control.pm b/lib/Config/Model/Backend/Dpkg/Control.pm
index c57cbd5..05ba69f 100644
--- a/lib/Config/Model/Backend/Dpkg/Control.pm
+++ b/lib/Config/Model/Backend/Dpkg/Control.pm
@@ -11,13 +11,10 @@ use Carp;
use Config::Model::Exception ;
use File::Path;
use Log::Log4perl qw(get_logger :levels);
-use AnyEvent ;
-use AnyEvent::HTTP ;
use Config::Model::Dpkg::Dependency;
my $logger = get_logger("Backend::Dpkg::Control") ;
-my $async_log = get_logger("Async::Value::Dependency") ;
sub suffix { return '' ; }
@@ -99,18 +96,8 @@ sub fill_package_cache {
}
}
- my $cv = AnyEvent->condvar ;
-
- $async_log->debug("start call to madison") ;
-
- my $cb = sub {
- $async_log->debug("call to madison done") ;
- $cv->send;
- } ;
-
my @pkgs = keys %packages;
- Config::Model::Dpkg::Dependency::cache_info_from_madison ($cb, @pkgs);
- $cv->recv;
+ Config::Model::Dpkg::Dependency::cache_info_from_madison (@pkgs);
}
sub read_sections {
diff --git a/lib/Config/Model/Dpkg/Dependency.pm b/lib/Config/Model/Dpkg/Dependency.pm
index 4506dc5..821a043 100644
--- a/lib/Config/Model/Dpkg/Dependency.pm
+++ b/lib/Config/Model/Dpkg/Dependency.pm
@@ -841,7 +841,7 @@ sub get_available_version {
# this function queries *once* madison for package info not found in cache.
# it should be called once when parsing control file
sub cache_info_from_madison {
- my ($callback, at pkg_names) = @_ ;
+ my (@pkg_names) = @_ ;
$logger->debug("called on @pkg_names");
@@ -861,7 +861,6 @@ sub cache_info_from_madison {
}
if (not $necessary) {
- $callback->();
return;
}
@@ -883,7 +882,6 @@ sub cache_info_from_madison {
foreach my $pname (keys %res) {
$cache{$pname} = time ." ".join(' ',@{$res{$pname}}) ;
}
- $callback->();
}
__PACKAGE__->meta->make_immutable;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libconfig-model-dpkg-perl.git
More information about the Pkg-perl-cvs-commits
mailing list