ソースを参照

* merged from the install-recommends branch

Michael Vogt 20 年 前
コミット
28f09b6cf0
共有1 個のファイルを変更した9 個の追加8 個の削除を含む
  1. 9 8
      apt-pkg/depcache.cc

+ 9 - 8
apt-pkg/depcache.cc

@@ -863,14 +863,15 @@ void pkgDepCache::MarkInstall(PkgIterator const &Pkg,bool AutoInst,
       {
 	 bool found=false;
 	 VerIterator instVer = Pkg.CurrentVer();
-	 for (DepIterator D = instVer.DependsList(); D.end() != true; D++)
-	 {
-	    //FIXME: deal better with or-groups(?)
-	    DepIterator LocalStart = D;
-	    
-	    if(IsImportantDep(D) && Start.TargetPkg() == D.TargetPkg())
-	       found=true;
-	 }
+	 if(!instVer.end())
+	    for (DepIterator D = instVer.DependsList(); D.end() != true; D++)
+	    {
+	       //FIXME: deal better with or-groups(?)
+	       DepIterator LocalStart = D;
+	       
+	       if(IsImportantDep(D) && Start.TargetPkg() == D.TargetPkg())
+		  found=true;
+	    }
 	 // this is a new dep if it was not found to be already
 	 // a important dep of the installed pacakge
 	 isNewImportantDep = !found;