diff options
Diffstat (limited to 'src/generic/apt')
-rw-r--r-- | src/generic/apt/aptcache.cc | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/generic/apt/aptcache.cc b/src/generic/apt/aptcache.cc index cba35e27..26f2338c 100644 --- a/src/generic/apt/aptcache.cc +++ b/src/generic/apt/aptcache.cc @@ -1099,15 +1099,10 @@ void aptitudeDepCache::internal_mark_install(const PkgIterator &Pkg, { dirty=true; - bool set_to_manual = ((Pkg.CurrentVer().end() && !(*this)[Pkg].Install()) || (!Pkg.CurrentVer().end() && (*this)[Pkg].Delete() && get_ext_state(Pkg).remove_reason == unused)); - if(set_to_manual) - MarkAuto(Pkg, false); - - // MarkInstall and friends like to modify the auto flag, so save it // here and restore it afterwards: bool previously_auto = ((*this)[Pkg].Flags & Flag::Auto) != 0; @@ -1123,6 +1118,9 @@ void aptitudeDepCache::internal_mark_install(const PkgIterator &Pkg, MarkAuto(Pkg, previously_auto); + if(set_to_manual) + MarkAuto(Pkg, false); + get_ext_state(Pkg).selection_state=pkgCache::State::Install; get_ext_state(Pkg).reinstall=ReInstall; get_ext_state(Pkg).forbidver=""; |