From d603afd970e4bc84ed7176b988cd72bd9cf339b3 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Wed, 3 Feb 2016 14:56:49 +0100 Subject: avoid building dependency tree in 'source' command We don't need the dependencies for obvious reasons and we don't need the candidate version either, so building a pkgDepCache is wasted effort, which we can stop doing now that build-dep cleared the path. --- apt-private/private-source.cc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'apt-private/private-source.cc') diff --git a/apt-private/private-source.cc b/apt-private/private-source.cc index c2f5f5d3a..7126feb78 100644 --- a/apt-private/private-source.cc +++ b/apt-private/private-source.cc @@ -317,13 +317,10 @@ struct DscFile }; bool DoSource(CommandLine &CmdL) { - CacheFile Cache; - if (Cache.Open(false) == false) - return false; - if (CmdL.FileSize() <= 1) return _error->Error(_("Must specify at least one package to fetch source for")); + CacheFile Cache; // Read the source list if (Cache.BuildSourceList() == false) return false; -- cgit v1.2.3