Browse code

Fix mismatch of fprintf format specifier and argument type

This fixes a warning about a mismatch between a fprintf format string
and an argument type on Darwin-64-bit builds:

%lu specifies type 'unsigned long' but the argument has type
'__darwin_suseconds_t' (aka 'int')

Acked-by: Arne Schwabe <arne@rfc2549.org>
Message-Id: <CAEsd45SoC+h5tcDraZcQN_MUYzqWYOVvNpkwMo190DLpB32StQ@mail.gmail.com>
URL: http://article.gmane.org/gmane.network.openvpn.devel/9446

Signed-off-by: Gert Doering <gert@greenie.muc.de>

Jonathan K. Bullard authored on 2015/02/07 04:49:10
Showing 1 changed files
... ...
@@ -319,7 +319,7 @@ void x_msg_va (const unsigned int flags, const char *format, va_list arglist)
319 319
 
320 320
 	      fprintf (fp, "%lu.%06lu %x %s%s%s%s",
321 321
 		       tv.tv_sec,
322
-		       tv.tv_usec,
322
+		       (unsigned long)tv.tv_usec,
323 323
 		       flags,
324 324
 		       prefix,
325 325
 		       prefix_sep,