diff options
-rw-r--r-- | apt-pkg/algorithms.cc | 2 | ||||
-rwxr-xr-x | test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict | 24 |
2 files changed, 25 insertions, 1 deletions
diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc index 3fdb5116e..ea6d4c39a 100644 --- a/apt-pkg/algorithms.cc +++ b/apt-pkg/algorithms.cc @@ -1043,7 +1043,7 @@ bool pkgProblemResolver::ResolveInternal(bool const BrokenFix) } // Skip adding to the kill list if it is protected - if (Cache[Pkg].Protect()) + if (Cache[Pkg].Protect() && Cache[Pkg].Mode != pkgDepCache::ModeDelete) continue; if (Debug == true) diff --git a/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict b/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict index 689699e15..480b6753e 100755 --- a/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict +++ b/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict @@ -25,6 +25,30 @@ Starting 2 pkgProblemResolver with broken count: 1 Investigating (0) init:amd64 < 1 @ii mK Ib > Broken init:amd64 PreDepends on systemd-sysv:amd64 < 1 @ii pmR > Considering systemd-sysv:amd64 0 as a solution to init:amd64 5100 + Added systemd-sysv:amd64 to the remove list +Broken init:amd64 PreDepends on sysvinit-core:amd64 < none @un pH > + Considering sysvinit-core:amd64 0 as a solution to init:amd64 5100 + Fixing init:amd64 via keep of systemd-sysv:amd64 + Ignore MarkKeep of systemd-sysv:amd64 < 1 @ii pmR > as its mode (Delete) is protected +Investigating (1) init:amd64 < 1 @ii mK Ib > +Broken init:amd64 PreDepends on systemd-sysv:amd64 < 1 @ii pmR > + Considering systemd-sysv:amd64 0 as a solution to init:amd64 5100 + Added systemd-sysv:amd64 to the remove list +Broken init:amd64 PreDepends on sysvinit-core:amd64 < none @un pH > + Considering sysvinit-core:amd64 0 as a solution to init:amd64 5100 + Fixing init:amd64 via keep of systemd-sysv:amd64 + Ignore MarkKeep of systemd-sysv:amd64 < 1 @ii pmR > as its mode (Delete) is protected +Investigating (2) init:amd64 < 1 @ii mK Ib > +Broken init:amd64 PreDepends on systemd-sysv:amd64 < 1 @ii pmR > + Considering systemd-sysv:amd64 0 as a solution to init:amd64 5100 + Added systemd-sysv:amd64 to the remove list +Broken init:amd64 PreDepends on sysvinit-core:amd64 < none @un pH > + Considering sysvinit-core:amd64 0 as a solution to init:amd64 5100 + Fixing init:amd64 via keep of systemd-sysv:amd64 + Ignore MarkKeep of systemd-sysv:amd64 < 1 @ii pmR > as its mode (Delete) is protected +Investigating (3) init:amd64 < 1 @ii mK Ib > +Broken init:amd64 PreDepends on systemd-sysv:amd64 < 1 @ii pmR > + Considering systemd-sysv:amd64 5100 as a solution to init:amd64 5100 Broken init:amd64 PreDepends on sysvinit-core:amd64 < none @un pH > Considering sysvinit-core:amd64 0 as a solution to init:amd64 5100 Or group remove for init:amd64 |