summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2005-11-30 13:53:44 +0000
committerMichael Vogt <michael.vogt@ubuntu.com>2005-11-30 13:53:44 +0000
commitb4e57d2dd44728929cb83113ed79c8e16405767e (patch)
tree536a31aacbac062a0b16d658002393bc09810c98
parentcec6091772ae3463cb04c417e3f598f9b6814516 (diff)
* hack around local file:/ uri problem
-rw-r--r--apt-pkg/acquire-item.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc
index 8a9a4c5bb..ad977dde4 100644
--- a/apt-pkg/acquire-item.cc
+++ b/apt-pkg/acquire-item.cc
@@ -165,11 +165,15 @@ pkgAcqDiffIndex::pkgAcqDiffIndex(pkgAcquire *Owner,
CurrentPackagesFile = _config->FindDir("Dir::State::lists");
CurrentPackagesFile += URItoFileName(RealURI);
+ // FIXME: this file:/ check is a hack to prevent fetching
+ // from local sources. this is really silly, and
+ // should be fixed cleanly as soon as possible
if(!FileExists(CurrentPackagesFile) ||
+ Desc.URI.substr(0,strlen("file:/")) == "file:/" ||
!_config->FindB("Acquire::Diffs",true)) {
// we don't have a pkg file or we don't want to queue
if(Debug)
- std::clog << "No index file or canceld by user" << std::endl;
+ std::clog << "No index file, local or canceld by user" << std::endl;
Failed("", NULL);
return;
}