From 933f51a8bfd1776690cd1cae2e01f35ec3bf3536 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sat, 31 May 2014 17:41:10 -0700 Subject: [PATCH] Only define struct timespec if _TIMESPEC_DEFINED isn't set This matches what the mingw-w64 headers define with the struct. --- include/threads.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/include/threads.h b/include/threads.h index cde4b91f..25a75625 100644 --- a/include/threads.h +++ b/include/threads.h @@ -33,11 +33,17 @@ typedef void (*altss_dtor_t)(void*); #include -#ifndef __MINGW32__ +#ifndef _TIMESPEC_DEFINED +#define _TIMESPEC_DEFINED struct timespec { time_t tv_sec; long tv_nsec; }; + +struct itimerspec { + struct timespec it_interval; + struct timespec it_value; +}; #endif typedef DWORD althrd_t;