]> Savannah Git Hosting - gnulib.git/commitdiff
Fix "warning: format specifies type 'unsigned long'".
authorBruno Haible <bruno@clisp.org>
Sun, 16 Aug 2020 11:00:57 +0000 (13:00 +0200)
committerBruno Haible <bruno@clisp.org>
Sun, 16 Aug 2020 11:00:57 +0000 (13:00 +0200)
* tests/test-nonblocking-writer.h (main_writer_loop): Cast dbgfprintf
argument to match the format directive.

ChangeLog
tests/test-nonblocking-writer.h

index d2b2277e562842a2f7c5bf127baef6132e485a17..c9392727639f3dfe7bbaf3856f5965062ad9cb99 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2020-08-16  Bruno Haible  <bruno@clisp.org>
 
+       Fix "warning: format specifies type 'unsigned long'".
+       * tests/test-nonblocking-writer.h (main_writer_loop): Cast dbgfprintf
+       argument to match the format directive.
+
        Fix "warning: no case matching constant switch condition '0'".
        * tests/test-fcntl.c (check_flags): Add a 'default' case.
 
index d579980392e7d5c04c104af9c492c24a77b62183..0cb491170b79ab2bfc1a33f93321441e61f5be79 100644 (file)
@@ -79,7 +79,7 @@ main_writer_loop (int test, size_t data_block_size, int fd,
         usleep (1000000);
 
         dbgfprintf (stderr, "%s:1: >> write (%lu)\n", PROG_ROLE,
-                    (unsigned long) 2 * data_block_size);
+                    (unsigned long) (2 * data_block_size));
         START_TIMING
         ret = write (fd, data, 2 * data_block_size);
         saved_errno = errno;