]> git.saurik.com Git - apt.git/commitdiff
merged from bzr+ssh://bazaar.launchpad.net/~donkult/apt/sid/
authorMichael Vogt <michael.vogt@ubuntu.com>
Fri, 20 Apr 2012 09:11:21 +0000 (11:11 +0200)
committerMichael Vogt <michael.vogt@ubuntu.com>
Fri, 20 Apr 2012 09:11:21 +0000 (11:11 +0200)
apt-pkg/aptconfiguration.cc

index f0cd8ebc088502ea0b33fc08fbb76205b978205d..e1225b3e623599e4a5b21a674841c78e02413adb 100644 (file)
@@ -61,12 +61,14 @@ const Configuration::getCompressionTypes(bool const &Cached) {
                if ((*o).empty() == true)
                        continue;
                // ignore types we have no method ready to use
-               if (_config->Exists(std::string("Acquire::CompressionTypes::").append(*o)) == false)
+               std::string const method = std::string("Acquire::CompressionTypes::").append(*o);
+               if (_config->Exists(method) == false)
                        continue;
                // ignore types we have no app ready to use
+               std::string const app = _config->Find(method);
                std::vector<APT::Configuration::Compressor>::const_iterator c = compressors.begin();
                for (; c != compressors.end(); ++c)
-                       if (c->Name == *o)
+                       if (c->Name == app)
                                break;
                if (c == compressors.end())
                        continue;