summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <egon@tas>2008-10-29 09:31:53 +0100
committerMichael Vogt <egon@tas>2008-10-29 09:31:53 +0100
commit708ead3a44ac2f5ea625343c5d1b3404cca8a481 (patch)
tree715b1e3d4654a26c83235f21e5eee1f3028b6203
parent589898ae1e46dc56bc037f502e1c405a3e06ed70 (diff)
apt-pkg/acquire-item.cc: do not hardcode "Packages" or "Sources" in the (generic) acquire-item.cc code
-rw-r--r--apt-pkg/acquire-item.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc
index cf835f5d5..ae8ff2205 100644
--- a/apt-pkg/acquire-item.cc
+++ b/apt-pkg/acquire-item.cc
@@ -717,7 +717,8 @@ void pkgAcqIndex::Done(string Message,unsigned long Size,string Hash,
decompProg = "bzip2";
else if(compExt == "gz")
decompProg = "gzip";
- else if(compExt == "Packages" || compExt == "Sources")
+ // flExtensions returns the full name if no extension is found
+ else if(compExt == flNotDir(URI(Desc.URI).Path))
decompProg = "copy";
else {
_error->Error("Unsupported extension: %s", compExt.c_str());