diff options
author | Pete Batard <pete@akeo.ie> | 2013-02-27 22:58:49 +0000 |
---|---|---|
committer | Pete Batard <pete@akeo.ie> | 2013-02-27 22:58:49 +0000 |
commit | 0ded9c126e9b48b5ed217e60d392cfb882cbc351 (patch) | |
tree | 96dcffe37667b4a47845a0e4d8d9af1b6c0022e1 /msvc | |
parent | c56f89068452f6ff144cd72ad234540049c06433 (diff) | |
download | libusb-0ded9c126e9b48b5ed217e60d392cfb882cbc351.tar.gz |
Misc: Simplify includes and misc. cleanup
* fxload sample provenance
* No need for <sys/types.h> in samples as already in libusb.h
* Don't bother about sscanf_s in xusb
* Use HAVE_### and rely on config.h where possible
* Formal inclusion of <winsock.h> in libusb.h for WinCE and WDK
* Cleanup of Windows' config.h
* Avoid ENAMETOOLONG and ENOTEMPTY conflict between errno.h and winsock.h for WinCE
* Additional newlines & braces cleanup
Diffstat (limited to 'msvc')
-rw-r--r-- | msvc/config.h | 25 | ||||
-rw-r--r-- | msvc/errno.h | 2 |
2 files changed, 11 insertions, 16 deletions
diff --git a/msvc/config.h b/msvc/config.h index eb05d3d..1814db5 100644 --- a/msvc/config.h +++ b/msvc/config.h @@ -17,28 +17,21 @@ /* Default visibility */ #define DEFAULT_VISIBILITY /**/ -/* Start with debug message logging enabled */ -//#define ENABLE_DEBUG_LOGGING 1 - -/* Message logging */ +/* Enable global message logging */ #define ENABLE_LOGGING 1 +/* Uncomment to start with debug message logging enabled */ +// #define ENABLE_DEBUG_LOGGING 1 + +/* type of second poll() argument */ +#define POLL_NFDS_TYPE unsigned int + /* Windows/WinCE backend */ #if defined(_WIN32_WCE) #define OS_WINCE 1 +#define HAVE_MISSING_H #else #define OS_WINDOWS 1 -#endif - -/* type of second poll() argument */ -#define POLL_NFDS_TYPE unsigned int - -#if !defined(_WIN32_WCE) - -/* Define to 1 if you have the <signal.h> header file. */ #define HAVE_SIGNAL_H 1 - -/* Define to 1 if you have the <sys/types.h> header file. */ #define HAVE_SYS_TYPES_H 1 - -#endif
\ No newline at end of file +#endif diff --git a/msvc/errno.h b/msvc/errno.h index a1d4f64..07d15e3 100644 --- a/msvc/errno.h +++ b/msvc/errno.h @@ -59,12 +59,14 @@ /* 35 - Unknown Error */ #define EDEADLOCK 36 /* Resource deadlock avoided (non-Cyg) */ #define EDEADLK 36 +#if 0 /* 37 - Unknown Error */ #define ENAMETOOLONG 38 /* Filename too long (91 in Cyg?) */ #define ENOLCK 39 /* No locks available (46 in Cyg?) */ #define ENOSYS 40 /* Function not implemented (88 in Cyg?) */ #define ENOTEMPTY 41 /* Directory not empty (90 in Cyg?) */ #define EILSEQ 42 /* Illegal byte sequence */ +#endif /* * NOTE: ENAMETOOLONG and ENOTEMPTY conflict with definitions in the |