summaryrefslogtreecommitdiff
path: root/apt-pkg/depcache.cc
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2011-02-17 18:34:36 +0100
committerMichael Vogt <michael.vogt@ubuntu.com>2011-02-17 18:34:36 +0100
commitcf62447e091a316de9959eb02d3c0a7b6d07e961 (patch)
tree09a8fe0773b87e4271d120cb0a3e13281228c153 /apt-pkg/depcache.cc
parent87f8f68c50f63b39b7a91e3aec0b5ef59069186d (diff)
parent8429cff25c3f1602dbff5e9b87d1522df34eafbc (diff)
merged from debian-sid
Diffstat (limited to 'apt-pkg/depcache.cc')
-rw-r--r--apt-pkg/depcache.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/apt-pkg/depcache.cc b/apt-pkg/depcache.cc
index a8bf4d3ae..cb1264b04 100644
--- a/apt-pkg/depcache.cc
+++ b/apt-pkg/depcache.cc
@@ -1261,8 +1261,10 @@ void pkgDepCache::MarkInstall(PkgIterator const &Pkg,bool AutoInst,
if(FromUser)
{
- // Set it to manual if it's a new install or already installed
- if(P.Status == 2 || Pkg->CurrentVer != 0)
+ // Set it to manual if it's a new install or already installed,
+ // but only if its not marked by the autoremover (aptitude depend on this behavior)
+ // or if we do automatic installation (aptitude never does it)
+ if(P.Status == 2 || (Pkg->CurrentVer != 0 && (AutoInst == true || P.Marked == false)))
P.Flags &= ~Flag::Auto;
}
else