Make mbedTLS compile with MS-DOS DJGPP

Signed-off-by: SuperIlu <superilu@yahoo.com>
This commit is contained in:
SuperIlu 2024-12-01 10:05:21 +01:00 committed by GitHub
parent 017722f043
commit 685d128c0f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -524,8 +524,8 @@ void mbedtls_net_usleep(unsigned long usec)
#else
struct timeval tv;
tv.tv_sec = usec / 1000000;
#if defined(__unix__) || defined(__unix) || \
(defined(__APPLE__) && defined(__MACH__))
#if (defined(__unix__) || defined(__unix) || \
(defined(__APPLE__) && defined(__MACH__))) && !defined(__DJGPP__)
tv.tv_usec = (suseconds_t) usec % 1000000;
#else
tv.tv_usec = usec % 1000000;