about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2016-01-27 22:24:58 +0100
committerMichael Biebl <biebl@debian.org>2016-01-27 22:25:42 +0100
commit59e6416758542e2a76eb7523e9901dbaa39ad750 (patch)
tree4c3e67b69f6e3fd40046940436fa2b2e4671f32f
parent6d3977e11a19667eaa8cb2cdfc772166f9afa89e (diff)
Use bash when running the tests for nm_utils_kill_child
The trap handling in dash seems to have issues, see #390433.
-rw-r--r--debian/changelog2
-rw-r--r--debian/patches/Use-bash-explicitly-when-running-the-tests.patch56
-rw-r--r--debian/patches/series1
3 files changed, 59 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog
index 0493b2a0..51fca4f4 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,8 @@ network-manager (1.1.90-3) UNRELEASED; urgency=medium
 
   * Add chroot capability to systemd service file. Needed for running openvpn.
     Patch cherry-picked from upstream Git.
+  * Use bash when running the tests for nm_utils_kill_child. The trap handling
+    in dash seems to have issues, see #390433.
 
  -- Michael Biebl <biebl@debian.org>  Wed, 27 Jan 2016 22:12:19 +0100
 
diff --git a/debian/patches/Use-bash-explicitly-when-running-the-tests.patch b/debian/patches/Use-bash-explicitly-when-running-the-tests.patch
new file mode 100644
index 00000000..c88953c4
--- /dev/null
+++ b/debian/patches/Use-bash-explicitly-when-running-the-tests.patch
@@ -0,0 +1,56 @@
+From: Michael Biebl <biebl@debian.org>
+Date: Wed, 27 Jan 2016 22:14:09 +0100
+Subject: Use bash explicitly when running the tests
+
+The trap handling in dash seems to have issues [Bug-Debian].
+So explicitly use bash when running the tests.
+
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=390433
+Bug: https://bugzilla.gnome.org/show_bug.cgi?id=761146
+---
+ src/tests/test-general-with-expect.c | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/src/tests/test-general-with-expect.c b/src/tests/test-general-with-expect.c
+index c6abdcc..a5ef9e3 100644
+--- a/src/tests/test-general-with-expect.c
++++ b/src/tests/test-general-with-expect.c
+@@ -225,33 +225,33 @@ test_nm_utils_kill_child (void)
+ 	int err;
+ 	GLogLevelFlags fatal_mask;
+ 	char *argv_watchdog[] = {
+-			"sh",
++			"bash",
+ 			"-c",
+ 			"sleep 4; "
+ 			"kill -KILL 0; #watchdog for #" TEST_TOKEN,
+ 			NULL,
+ 		};
+ 	char *argv1[] = {
+-			"sh",
++			"bash",
+ 			"-c",
+ 			"trap \"sleep 0.3; exit 10\" EXIT; "
+ 			"sleep 100000; exit $? #" TEST_TOKEN,
+ 			NULL,
+ 		};
+ 	char *argv2[] = {
+-			"sh",
++			"bash",
+ 			"-c",
+ 			"exit 47; #" TEST_TOKEN,
+ 			NULL,
+ 		};
+ 	char *argv3[] = {
+-			"sh",
++			"bash",
+ 			"-c",
+ 			"trap \"exit 47\" TERM; while true; do :; done; #" TEST_TOKEN,
+ 			NULL,
+ 		};
+ 	char *argv4[] = {
+-			"sh",
++			"bash",
+ 			"-c",
+ 			"trap \"while true; do :; done\" TERM; while true; do :; done; #" TEST_TOKEN,
+ 			NULL,
diff --git a/debian/patches/series b/debian/patches/series
index 41b67091..50f4487c 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -10,3 +10,4 @@ Fix-iscsiadm-path.patch
 libnm-vpn-restore-export-of-deprecated-NMVpnPluginOld-sym.patch
 tests-use-dbus-run-session-instead-of-dbus-launch.patch
 systemd-add-chroot-capability.patch
+Use-bash-explicitly-when-running-the-tests.patch