Skip to contentSkip to conversation

LVM2/test not.c

PATCH [email protected] 1 participant 1 message Feb 17, 2009

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: mornfall at sourceware.org 2009-02-17 19:37:28

Modified files:
test : not.c

Log message:
In testsuite's not.c, print a notice when program dies of a fatal signal.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/test/not.c.diff?cvsroot=lvm2&r1=1.1&r2=1.2

test/not.c +4 -0
@@ -25,6 +25,10 @@
 	} else {		/* parent */
 		waitpid(pid, &status, 0);
 		if (!WIFEXITED(status)) {
+			if (WIFSIGNALED(status))
+				fprintf(stderr,
+					"Process %d died of signal %d.\n",
+					pid, WTERMSIG(status));
 			/* did not exit correctly */
 			return FAILURE;
 		}