Michael Vogt лет назад: 19
Родитель
Сommit
ff6bf1be38
2 измененных файлов с 3 добавлено и 3 удалено
  1. 3 2
      apt-pkg/contrib/configuration.cc
  2. 0 1
      apt-pkg/depcache.cc

+ 3 - 2
apt-pkg/contrib/configuration.cc

@@ -422,6 +422,7 @@ bool Configuration::ExistsAny(const char *Name) const
    string key = Name;
 
    if (key.size() > 2 && key.end()[-2] == '/')
+   {
       if (key.find_first_of("fdbi",key.size()-1) < key.size())
       {
          key.resize(key.size() - 2);
@@ -432,7 +433,7 @@ bool Configuration::ExistsAny(const char *Name) const
       {
          _error->Warning(_("Unrecognized type abbreviation: '%c'"), key.end()[-3]);
       }
-
+   }
    return Exists(Name);
 }
 									/*}}}*/
@@ -506,7 +507,7 @@ bool ReadConfigFile(Configuration &Conf,const string &FName,bool AsSectional,
       CurLine++;
       // This should be made to work instead, but this is better than looping
       if (F.fail() && !F.eof())
-         return _error->Error(_("Line %d too long (max %d)"), CurLine, sizeof(Buffer));
+         return _error->Error(_("Line %d too long (max %lu)"), CurLine, sizeof(Buffer));
 
       _strtabexpand(Buffer,sizeof(Buffer));
       _strstrip(Buffer);

+ 0 - 1
apt-pkg/depcache.cc

@@ -216,7 +216,6 @@ bool pkgDepCache::writeStateFile(OpProgress *prog, bool InstalledOnly)
 	 pkgCache::PkgIterator pkg=Cache->FindPkg(pkgname);
 	 if(pkg.end() || pkg.VersionList().end()) 
 	    continue;
-	 bool oldAuto = section.FindI("Auto-Installed");
 	 bool newAuto = (PkgState[pkg->ID].Flags & Flag::Auto);
 	 if(_config->FindB("Debug::pkgAutoRemove",false))
 	    std::clog << "Update exisiting AutoInstall info: "