summaryrefslogtreecommitdiff
path: root/cmdline/apt-internal-solver.cc
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2014-08-17 13:27:59 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2014-09-27 00:10:14 +0200
commit67caa2e6538f13ff7a0d77e98ad6c58af998376d (patch)
treed7ec492d7a54460a0d94b322911dda2b2595a514 /cmdline/apt-internal-solver.cc
parent2a884c612b10b27f4be2cc6dd689bfe448d9361a (diff)
mark pkg(All|Dist)Upgrade as deprecated
The comment above their definition marks them already as such, so this is only a formalisation of the deprecation and fixes the occurances we have in our own code together with removing a magic number. Git-Dch: Ignore
Diffstat (limited to 'cmdline/apt-internal-solver.cc')
-rw-r--r--cmdline/apt-internal-solver.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmdline/apt-internal-solver.cc b/cmdline/apt-internal-solver.cc
index c24a96cdf..0f2ec6283 100644
--- a/cmdline/apt-internal-solver.cc
+++ b/cmdline/apt-internal-solver.cc
@@ -175,10 +175,10 @@ int main(int argc,const char *argv[]) /*{{{*/
std::string failure;
if (upgrade == true) {
- if (pkgAllUpgrade(CacheFile) == false)
+ if (APT::Upgrade::Upgrade(CacheFile, APT::Upgrade::FORBID_REMOVE_PACKAGES | APT::Upgrade::FORBID_INSTALL_NEW_PACKAGES) == false)
failure = "ERR_UNSOLVABLE_UPGRADE";
} else if (distUpgrade == true) {
- if (pkgDistUpgrade(CacheFile) == false)
+ if (APT::Upgrade::Upgrade(CacheFile, APT::Upgrade::ALLOW_EVERYTHING) == false)
failure = "ERR_UNSOLVABLE_DIST_UPGRADE";
} else if (Fix.Resolve() == false)
failure = "ERR_UNSOLVABLE";