changeset 15381:dbd7d36edadc

test-sigprocmask: avoid compiler warning * modules/sigprocmask-tests (Depends-on): Add ignore-value. * tests/test-sigprocmask.c (main): Use it to silence warning. Reported by Jim Meyering. Signed-off-by: Eric Blake <eblake@redhat.com>
author Eric Blake <eblake@redhat.com>
date Fri, 08 Jul 2011 15:55:40 -0600
parents 84ad6dbce2a8
children 16995a7f1514
files ChangeLog modules/sigprocmask-tests tests/test-sigprocmask.c
diffstat 3 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 2011-07-08  Eric Blake  <eblake@redhat.com>
 
+	test-sigprocmask: avoid compiler warning
+	* modules/sigprocmask-tests (Depends-on): Add ignore-value.
+	* tests/test-sigprocmask.c (main): Use it to silence warning.
+	Reported by Jim Meyering.
+
 	test-snprintf: avoid compiler warning
 	* tests/test-snprintf.c (main): Avoid shadowed declaration.
 	* tests/test-vsnprintf.c (main): Likewise.
--- a/modules/sigprocmask-tests
+++ b/modules/sigprocmask-tests
@@ -4,6 +4,7 @@
 tests/macros.h
 
 Depends-on:
+ignore-value
 sleep
 
 configure.ac:
--- a/tests/test-sigprocmask.c
+++ b/tests/test-sigprocmask.c
@@ -28,6 +28,7 @@
 #include <stdlib.h>
 #include <unistd.h>
 
+#include "ignore-value.h"
 #include "macros.h"
 
 #if !((defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__)
@@ -61,7 +62,7 @@
 
   /* Request a SIGINT signal from outside.  */
   sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
-  system (command);
+  ignore_value (system (command));
 
   /* Wait.  */
   sleep (2);