tests: Ignore return value from fwrite.
authorRichard W.M. Jones <rjones@redhat.com>
Wed, 16 Mar 2011 11:50:16 +0000 (11:50 +0000)
committerRichard W.M. Jones <rjones@redhat.com>
Wed, 16 Mar 2011 11:50:16 +0000 (11:50 +0000)
capitests/Makefile.am
capitests/test-debug-to-file.c

index 89d29e0..487a33f 100644 (file)
@@ -117,9 +117,11 @@ test_private_data_LDADD = \
 test_debug_to_file_SOURCES = test-debug-to-file.c
 test_debug_to_file_CFLAGS = \
        -I$(top_srcdir)/src -I$(top_builddir)/src \
+       -I$(top_srcdir)/gnulib/lib \
        $(WARN_CFLAGS) $(WERROR_CFLAGS)
 test_debug_to_file_LDADD = \
-       $(top_builddir)/src/libguestfs.la
+       $(top_builddir)/src/libguestfs.la \
+       ../gnulib/lib/libgnu.la
 
 #if HAVE_LIBVIRT
 #test_add_libvirt_dom_SOURCES = test-add-libvirt-dom.c
index 6d1b619..5eb5610 100644 (file)
@@ -27,6 +27,8 @@
 #include <string.h>
 #include <unistd.h>
 
+#include "ignore-value.h"
+
 #include "guestfs.h"
 
 static void
@@ -40,7 +42,7 @@ debug_to_file (guestfs_h *g,
 {
   FILE *fp = opaque;
 
-  fwrite (buf, 1, buf_len, fp);
+  ignore_value (fwrite (buf, 1, buf_len, fp));
 }
 
 int