From 2aad19b93d64490bbf85c21c042821f2a16a0d9a Mon Sep 17 00:00:00 2001 From: Xiaofan Chen Date: Sat, 14 Apr 2012 23:17:18 +0800 Subject: [PATCH] Linux: Silence unused variable warnings without CLOCK_MONOTONIC --- libusb/os/linux_usbfs.c | 2 +- libusb/version.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libusb/os/linux_usbfs.c b/libusb/os/linux_usbfs.c index f2b312d..416efc4 100644 --- a/libusb/os/linux_usbfs.c +++ b/libusb/os/linux_usbfs.c @@ -207,10 +207,10 @@ static const char *find_usbfs_path(void) * seem to lack it). fall back to REALTIME if we have to. */ static clockid_t find_monotonic_clock(void) { +#ifdef CLOCK_MONOTONIC struct timespec ts; int r; -#ifdef CLOCK_MONOTONIC /* Linux 2.6.28 adds CLOCK_MONOTONIC_RAW but we don't use it * because it's not available through timerfd */ r = clock_gettime(CLOCK_MONOTONIC, &ts); diff --git a/libusb/version.h b/libusb/version.h index 1b94eb6..b4386fc 100644 --- a/libusb/version.h +++ b/libusb/version.h @@ -9,7 +9,7 @@ #define LIBUSB_MICRO 10 #endif #ifndef LIBUSB_NANO -#define LIBUSB_NANO 10478 +#define LIBUSB_NANO 10479 #endif /* LIBUSB_RC is the release candidate suffix. Should normally be empty. */ #ifndef LIBUSB_RC -- 2.7.4