summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/changelog4
-rw-r--r--src/packages.c10
2 files changed, 13 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index 149f4daa1..01419f46b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,10 @@ dpkg (1.17.20) UNRELEASED; urgency=low
[ Guillem Jover ]
* Add a requeueing insertion protection for process_queue().
+ * Make sure to always switch to the next dependtry after we have made no
+ progress for a while. Regression stemming from non future proof changes
+ introduced with the initial triggers implementation in dpkg 1.14.17
+ combined with changes in dpkg 1.17.19. Closes: #766242, #766322
[ Updated programs translations ]
* German (Sven Joachim).
diff --git a/src/packages.c b/src/packages.c
index 290565157..67b18c060 100644
--- a/src/packages.c
+++ b/src/packages.c
@@ -217,7 +217,15 @@ void process_queue(void) {
action_todo = cipaction->arg_int;
- if (sincenothing++ > queue.length * 2 + 2) {
+ if (sincenothing++ > queue.length * 3 + 2) {
+ /* Make sure that even if we have exceeded the queue since not having
+ * made any progress, we are not getting stuck trying to progress by
+ * trigger processing, w/o jumping into the next dependtry. */
+ dependtry++;
+ sincenothing = 0;
+ assert(dependtry <= 4);
+ } else if (sincenothing > queue.length * 2 + 2) {
+ /* XXX: This probably needs moving into a new dependtry instead. */
if (progress_bytrigproc && progress_bytrigproc->trigpend_head) {
enqueue_package(pkg);
pkg = progress_bytrigproc;