]>
Commit | Line | Data |
---|---|---|
1 | diff -urp libusb-1.0.9.orig/libusb/io.c libusb-1.0.9/libusb/io.c | |
2 | --- libusb-1.0.9.orig/libusb/io.c 2013-08-28 14:33:15.000000000 +0200 | |
3 | +++ libusb-1.0.9/libusb/io.c 2013-08-28 14:31:25.000000000 +0200 | |
4 | @@ -36,6 +36,14 @@ | |
5 | ||
6 | #include "libusbi.h" | |
7 | ||
8 | +#ifndef TIMESPEC_TO_TIMEVAL | |
9 | +#define TIMESPEC_TO_TIMEVAL(tv, ts) \ | |
10 | + do { \ | |
11 | + (tv)->tv_sec = (ts)->tv_sec; \ | |
12 | + (tv)->tv_usec = (ts)->tv_nsec / 1000; \ | |
13 | + } while (0) | |
14 | +#endif | |
15 | + | |
16 | /** | |
17 | * \page io Synchronous and asynchronous device I/O | |
18 | * |