summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Rousseau <ludovic.rousseau@gmail.com>2012-06-01 11:52:17 +0200
committerPete Batard <pete@akeo.ie>2012-06-04 01:27:11 +0100
commita7ab6bafa952bd8ae2d24a2d0aa89efaab70fc10 (patch)
tree12dfb8f19ccabf0aadfec8f2f9fa8f8703953898
parent56853b54d05e36834c3e7a99afda526d0c57eb18 (diff)
Core: Fix "LOG_LEVEL_NONE not handled in switch" warning
-rw-r--r--libusb/core.c4
-rw-r--r--libusb/version_nano.h2
2 files changed, 4 insertions, 2 deletions
diff --git a/libusb/core.c b/libusb/core.c
index 62dd15a..6540fd3 100644
--- a/libusb/core.c
+++ b/libusb/core.c
@@ -1784,7 +1784,7 @@ int usbi_gettimeofday(struct timeval *tp, void *tzp)
void usbi_log_v(struct libusb_context *ctx, enum usbi_log_level level,
const char *function, const char *format, va_list args)
{
- const char *prefix;
+ const char *prefix = "";
struct timeval now;
int global_debug;
static int has_debug_header_been_displayed = 0;
@@ -1828,6 +1828,8 @@ void usbi_log_v(struct libusb_context *ctx, enum usbi_log_level level,
case LOG_LEVEL_DEBUG:
prefix = "debug";
break;
+ case LOG_LEVEL_NONE:
+ break;
default:
prefix = "unknown";
break;
diff --git a/libusb/version_nano.h b/libusb/version_nano.h
index b561cf6..9687da3 100644
--- a/libusb/version_nano.h
+++ b/libusb/version_nano.h
@@ -1 +1 @@
-#define LIBUSB_NANO 10517
+#define LIBUSB_NANO 10518