martin f. krafft: Trap SIGINT in bugscript to prevent incomplete reports

Martin F. Krafft madduck at alioth.debian.org
Tue May 5 13:41:59 UTC 2009


Module: mdadm
Branch: maint/lenny
Commit: 8063eb35295c7ac5aa1015801088aebf695d80ba
URL:    http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commit;h=8063eb35295c7ac5aa1015801088aebf695d80ba

Author: martin f. krafft <madduck at debian.org>
Date:   Tue May  5 11:44:41 2009 +0200

Trap SIGINT in bugscript to prevent incomplete reports

Signed-off-by: martin f. krafft <madduck at debian.org>

---

 debian/bugscript |    3 +++
 debian/changelog |    2 ++
 2 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/debian/bugscript b/debian/bugscript
index 3aa5ae2..5ebb2f1 100755
--- a/debian/bugscript
+++ b/debian/bugscript
@@ -28,6 +28,9 @@ if ! command -v yesno >/dev/null; then
   exec 3>&1
 fi
 
+# do not let people ctrl-c out of the bugscript
+trap : INT
+
 if [ $(id -u) != 0 ]; then
   if [ -x "$(command -v sudo)" ]; then
     yesno "Gather system information as root using sudo? (Y/n) " yep
diff --git a/debian/changelog b/debian/changelog
index 549b119..aae56b7 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,8 @@ mdadm (2.6.7.2-3) stable-proposed-updates; urgency=low
     a normal user.
   * Include MD5 sums of md-related files in initrd in bug reports.
   * Add grub2 information retrieval to bugscript.
+  * Trap SIGINT and thus prevent ctrl-c from terminating the bugscript
+    prematurely.
 
  -- martin f. krafft <madduck at debian.org>  Tue, 05 May 2009 08:45:22 +0200
 




More information about the pkg-mdadm-commits mailing list