diff options
Diffstat (limited to 'apt-pkg')
-rw-r--r-- | apt-pkg/depcache.cc | 7 | ||||
-rw-r--r-- | apt-pkg/tagfile.cc | 3 |
2 files changed, 8 insertions, 2 deletions
diff --git a/apt-pkg/depcache.cc b/apt-pkg/depcache.cc index dd1c794c9..58d1d25e5 100644 --- a/apt-pkg/depcache.cc +++ b/apt-pkg/depcache.cc @@ -16,7 +16,8 @@ #include <apt-pkg/error.h> #include <apt-pkg/sptr.h> #include <apt-pkg/algorithms.h> - +#include <apt-pkg/configuration.h> + #include <apti18n.h> /*}}}*/ @@ -712,6 +713,10 @@ void pkgDepCache::MarkInstall(PkgIterator const &Pkg,bool AutoInst, if (InstPkg.end() == false) { + if(_config->FindB("Debug::pkgDepCache::AutoInstall",false) == true) + std::clog << "Installing " << InstPkg.Name() + << " as dep of " << Pkg.Name() + << std::endl; MarkInstall(InstPkg,true,Depth + 1); // Set the autoflag, after MarkInstall because MarkInstall unsets it diff --git a/apt-pkg/tagfile.cc b/apt-pkg/tagfile.cc index dc1ba3f9e..79ff18de4 100644 --- a/apt-pkg/tagfile.cc +++ b/apt-pkg/tagfile.cc @@ -98,7 +98,8 @@ bool pkgTagFile::Jump(pkgTagSection &Tag,unsigned long Offset) iOffset = Offset; Start = Buffer + iOffset; - if (Tag.Scan(Start,End - Start) == false) + // Start != End is a special case to not fail on empty TagFiles + if (Start != End && Tag.Scan(Start,End - Start) == false) return _error->Error(_("Unable to parse package file %s (2)"),Fd.Name().c_str()); return true; |