diff options
author | Christophe Fergeau <cfergeau@redhat.com> | 2012-02-29 19:01:56 +0100 |
---|---|---|
committer | Alon Levy <alevy@redhat.com> | 2012-03-04 10:50:38 +0200 |
commit | 58b9aa98535586d024033b09a03fca6a1469334e (patch) | |
tree | 24e9f222dd6fd5629ba235462b9663ae87cce460 /client | |
parent | 4ec9ac20fce858d7fe6769b14b521b62c64c828c (diff) |
mingw: add workaround for _ftime_s issue on mingw
mingw has a _ftime_s prototype in its headers, but no corresponding
symbol available at link time. Workaround this issue for now by
#defining it to _ftime. This is untested on win64 where the workaround
may not be needed.
Diffstat (limited to 'client')
-rw-r--r-- | client/threads.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/client/threads.cpp b/client/threads.cpp index bf499e72..e255beed 100644 --- a/client/threads.cpp +++ b/client/threads.cpp @@ -28,6 +28,13 @@ #ifdef HAVE_SYS_TIME_H #include <sys/time.h> #endif +#ifdef __MINGW32__ +//workaround for what I think is a mingw bug: it has a prototype for +//_ftime_s in its headers, but no symbol for it at link time. +//The #define from common.h cannot be used since it breaks other mingw +//headers if any are included after the #define. +#define _ftime_s _ftime +#endif Thread::Thread(thread_main_t thread_main, void* opaque) { |