]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/algorithms.cc
make all d-pointer * const pointers
[apt.git] / apt-pkg / algorithms.cc
index b8383105348421cf7457f8e41642e8ad739074fb..db765febe0cb9b8c5c58eb29b36861d470d1c256 100644 (file)
@@ -43,7 +43,7 @@ pkgProblemResolver *pkgProblemResolver::This = 0;
 /* The legacy translations here of input Pkg iterators is obsolete, 
    this is not necessary since the pkgCaches are fully shared now. */
 pkgSimulate::pkgSimulate(pkgDepCache *Cache) : pkgPackageManager(Cache),
 /* The legacy translations here of input Pkg iterators is obsolete, 
    this is not necessary since the pkgCaches are fully shared now. */
 pkgSimulate::pkgSimulate(pkgDepCache *Cache) : pkgPackageManager(Cache),
-                           iPolicy(Cache),
+                           d(NULL), iPolicy(Cache),
                            Sim(&Cache->GetCache(),&iPolicy),
                            group(Sim)
 {
                            Sim(&Cache->GetCache(),&iPolicy),
                            group(Sim)
 {
@@ -640,13 +640,17 @@ bool pkgProblemResolver::DoUpgrade(pkgCache::PkgIterator Pkg)
 // ProblemResolver::Resolve - calls a resolver to fix the situation    /*{{{*/
 // ---------------------------------------------------------------------
 /* */
 // ProblemResolver::Resolve - calls a resolver to fix the situation    /*{{{*/
 // ---------------------------------------------------------------------
 /* */
+#if APT_PKG_ABI < 413
 bool pkgProblemResolver::Resolve(bool BrokenFix)
 bool pkgProblemResolver::Resolve(bool BrokenFix)
+{
+   return Resolve(BrokenFix, NULL);
+}
+#endif
+bool pkgProblemResolver::Resolve(bool BrokenFix, OpProgress * const Progress)
 {
    std::string const solver = _config->Find("APT::Solver", "internal");
 {
    std::string const solver = _config->Find("APT::Solver", "internal");
-   if (solver != "internal") {
-      OpTextProgress Prog(*_config);
-      return EDSP::ResolveExternal(solver.c_str(), Cache, false, false, false, &Prog);
-   }
+   if (solver != "internal")
+      return EDSP::ResolveExternal(solver.c_str(), Cache, false, false, false, Progress);
    return ResolveInternal(BrokenFix);
 }
                                                                        /*}}}*/
    return ResolveInternal(BrokenFix);
 }
                                                                        /*}}}*/
@@ -1140,13 +1144,17 @@ bool pkgProblemResolver::InstOrNewPolicyBroken(pkgCache::PkgIterator I)
 /* This is the work horse of the soft upgrade routine. It is very gental 
    in that it does not install or remove any packages. It is assumed that the
    system was non-broken previously. */
 /* This is the work horse of the soft upgrade routine. It is very gental 
    in that it does not install or remove any packages. It is assumed that the
    system was non-broken previously. */
+#if APT_PKG_ABI < 413
 bool pkgProblemResolver::ResolveByKeep()
 bool pkgProblemResolver::ResolveByKeep()
+{
+   return ResolveByKeep(NULL);
+}
+#endif
+bool pkgProblemResolver::ResolveByKeep(OpProgress * const Progress)
 {
    std::string const solver = _config->Find("APT::Solver", "internal");
 {
    std::string const solver = _config->Find("APT::Solver", "internal");
-   if (solver != "internal") {
-      OpTextProgress Prog(*_config);
-      return EDSP::ResolveExternal(solver.c_str(), Cache, true, false, false, &Prog);
-   }
+   if (solver != "internal")
+      return EDSP::ResolveExternal(solver.c_str(), Cache, true, false, false, Progress);
    return ResolveByKeepInternal();
 }
                                                                        /*}}}*/
    return ResolveByKeepInternal();
 }
                                                                        /*}}}*/