Core: Fix #122 warning: no previous prototype for ‘usbi_log_v’
authorLudovic Rousseau <ludovic.rousseau+github@gmail.com>
Sat, 24 Sep 2011 16:27:54 +0000 (18:27 +0200)
committerPeter Stuge <peter@stuge.se>
Tue, 13 Dec 2011 10:11:58 +0000 (11:11 +0100)
Declare the usbi_log_v() function before using it.

libusb/libusbi.h

index fe9b7af..39ac55d 100644 (file)
@@ -26,6 +26,7 @@
 #include <stddef.h>
 #include <stdint.h>
 #include <time.h>
+#include <stdarg.h>
 #ifdef HAVE_POLL_H
 #include <poll.h>
 #endif
@@ -127,6 +128,9 @@ enum usbi_log_level {
 void usbi_log(struct libusb_context *ctx, enum usbi_log_level level,
        const char *function, const char *format, ...);
 
+void usbi_log_v(struct libusb_context *ctx, enum usbi_log_level level,
+       const char *function, const char *format, va_list args);
+
 #if !defined(_MSC_VER) || _MSC_VER > 1200
 
 #ifdef ENABLE_LOGGING
@@ -147,9 +151,6 @@ void usbi_log(struct libusb_context *ctx, enum usbi_log_level level,
 
 #else /* !defined(_MSC_VER) || _MSC_VER > 1200 */
 
-void usbi_log_v(struct libusb_context *ctx, enum usbi_log_level level,
-       const char *function, const char *format, va_list args);
-
 #ifdef ENABLE_LOGGING
 #define LOG_BODY(ctxt, level) \
 {                             \