[Piuparts-commits] [piuparts] 02/23: p: run panic handlers in reverse order

Holger Levsen holger at layer-acht.org
Tue Jan 17 12:39:45 UTC 2017


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch develop
in repository piuparts.

commit 8a1f3354eae804bd5293c2be8215bcd795f05c3f
Author: Andreas Beckmann <anbe at debian.org>
Date:   Mon Jan 16 01:47:37 2017 +0100

    p: run panic handlers in reverse order
    
    Signed-off-by: Andreas Beckmann <anbe at debian.org>
    Signed-off-by: Holger Levsen <holger at layer-acht.org>
---
 debian/changelog | 2 ++
 piuparts.py      | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 59046e4..bf31b48 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,5 +1,7 @@
 piuparts (0.75) UNRELEASED; urgency=medium
 
+  * piuparts.py:
+    - Run panic handlers in reverse order.
   * Add/adjust some exceptions for ancient packages.
 
  -- Andreas Beckmann <anbe at debian.org>  Sun, 15 Jan 2017 20:34:58 +0100
diff --git a/piuparts.py b/piuparts.py
index 8c9363a..405d9e0 100644
--- a/piuparts.py
+++ b/piuparts.py
@@ -456,7 +456,7 @@ def dump(msg):
 
 
 def panic(exit=1):
-    for i in range(counter):
+    for i in reversed(range(counter)):
         if i in on_panic_hooks:
             on_panic_hooks[i]()
     logging.error("piuparts run ends.")

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/piuparts/piuparts.git



More information about the Piuparts-commits mailing list