summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apt-pkg/algorithms.cc6
-rw-r--r--apt-pkg/algorithms.h7
-rw-r--r--cmdline/apt-get.cc4
3 files changed, 9 insertions, 8 deletions
diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc
index 6cde4d6cc..d19783983 100644
--- a/apt-pkg/algorithms.cc
+++ b/apt-pkg/algorithms.cc
@@ -1440,9 +1440,11 @@ bool pkgProblemResolver::ResolveByKeepInternal()
return true;
}
/*}}}*/
-// ProblemResolver::InstallProtect - Install all protected packages /*{{{*/
+// ProblemResolver::InstallProtect - deprecated cpu-eating no-op /*{{{*/
// ---------------------------------------------------------------------
-/* This is used to make sure protected packages are installed */
+/* Actions issued with FromUser bit set are protected from further
+ modification (expect by other calls with FromUser set) nowadays , so we
+ don't need to reissue actions here, they are already set in stone. */
void pkgProblemResolver::InstallProtect()
{
pkgDepCache::ActionGroup group(Cache);
diff --git a/apt-pkg/algorithms.h b/apt-pkg/algorithms.h
index aff8a68f2..7f58c8eed 100644
--- a/apt-pkg/algorithms.h
+++ b/apt-pkg/algorithms.h
@@ -36,6 +36,8 @@
#include <iostream>
+#include <apt-pkg/macros.h>
+
#ifndef APT_8_CLEANER_HEADERS
#include <apt-pkg/acquire.h>
using std::ostream;
@@ -132,9 +134,8 @@ class pkgProblemResolver /*{{{*/
// Try to resolve problems only by using keep
bool ResolveByKeep();
- // Install all protected packages
- void InstallProtect();
-
+ __deprecated void InstallProtect();
+
pkgProblemResolver(pkgDepCache *Cache);
~pkgProblemResolver();
};
diff --git a/cmdline/apt-get.cc b/cmdline/apt-get.cc
index 999f2a6a7..85ed80a95 100644
--- a/cmdline/apt-get.cc
+++ b/cmdline/apt-get.cc
@@ -1962,7 +1962,6 @@ bool DoInstall(CommandLine &CmdL)
if (Fix != NULL)
{
// Call the scored problem resolver
- Fix->InstallProtect();
Fix->Resolve(true);
delete Fix;
}
@@ -3123,8 +3122,7 @@ bool DoBuildDep(CommandLine &CmdL)
}
}
}
-
- Fix.InstallProtect();
+
if (Fix.Resolve(true) == false)
_error->Discard();