mirror of
https://github.com/isar/libmdbx.git
synced 2025-08-19 19:39:26 +08:00
mdbx: resolve all warnings from MinGW.
This commit is contained in:
@@ -78,6 +78,12 @@ time from_ms(uint64_t ms) {
|
||||
return result;
|
||||
}
|
||||
|
||||
#if __GNUC_PREREQ(8, 0) && \
|
||||
(defined(__MINGW__) || defined(__MINGW32__) || defined(__MINGW64__))
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wcast-function-type"
|
||||
#endif /* GCC/MINGW */
|
||||
|
||||
time now_realtime() {
|
||||
#if defined(_WIN32) || defined(_WIN64) || defined(_WINDOWS)
|
||||
static void(WINAPI * query_time)(LPFILETIME);
|
||||
@@ -133,4 +139,9 @@ time now_monotonic() {
|
||||
#endif
|
||||
}
|
||||
|
||||
#if __GNUC_PREREQ(8, 0) && \
|
||||
(defined(__MINGW__) || defined(__MINGW32__) || defined(__MINGW64__))
|
||||
#pragma GCC diagnostic pop
|
||||
#endif /* GCC/MINGW */
|
||||
|
||||
} /* namespace chrono */
|
||||
|
@@ -75,7 +75,7 @@ void osal_setup(const std::vector<actor_config> &actors) {
|
||||
if (!hEvent)
|
||||
failure_perror("CreateEvent()", GetLastError());
|
||||
hEvent = make_inheritable(hEvent);
|
||||
log_trace("osal_setup: event %" PRIuPTR " -> %p", i, hEvent);
|
||||
log_trace("osal_setup: event %u -> %p", i, hEvent);
|
||||
events[i] = hEvent;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user