mirror of
https://github.com/Mbed-TLS/mbedtls-framework.git
synced 2026-11-08 08:22:50 +00:00
fix wrong target detection
For mingw with `-std=c99`, WIN32 is not defined. Signed-off-by: Jerry Yu <[email protected]>
This commit is contained in:
@@ -10,7 +10,8 @@
|
||||
#if defined(MBEDTLS_HAVE_TIME)
|
||||
#include "mbedtls/platform_time.h"
|
||||
|
||||
#ifdef WIN32
|
||||
#if defined(_WIN32) || defined(WIN32) || defined(__CYGWIN__) || \
|
||||
defined(__MINGW32__) || defined(_WIN64)
|
||||
#include <windows.h>
|
||||
#elif _POSIX_C_SOURCE >= 199309L
|
||||
#include <time.h>
|
||||
@@ -19,7 +20,8 @@
|
||||
#endif
|
||||
void sleep_ms(int milliseconds)
|
||||
{
|
||||
#ifdef WIN32
|
||||
#if defined(_WIN32) || defined(WIN32) || defined(__CYGWIN__) || \
|
||||
defined(__MINGW32__) || defined(_WIN64)
|
||||
Sleep(milliseconds);
|
||||
#elif _POSIX_C_SOURCE >= 199309L
|
||||
struct timespec ts;
|
||||
|
||||
Reference in New Issue
Block a user