aboutsummaryrefslogtreecommitdiffstats
path: root/testing/wiringx/fix_time_t.patch
blob: bb796263675d6bd50f71e510f1dcdf994a9a46c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
--- a/src/wiringx.c	2019-11-26 22:02:22.000000000 +0000
+++ b/src/wiringx.c	2019-12-02 15:33:57.453242143 +0000
@@ -117,8 +117,8 @@
 	tLong.tv_sec  = howLong / 1000000;
 	tLong.tv_usec = howLong % 1000000;
 #else
-	tLong.tv_sec  = (__time_t)howLong / 1000000;
-	tLong.tv_usec = (__suseconds_t)howLong % 1000000;
+	tLong.tv_sec  = (time_t)howLong / 1000000;
+	tLong.tv_usec = (suseconds_t)howLong % 1000000;
 #endif
 	timeradd(&tNow, &tLong, &tEnd);
 
@@ -133,7 +133,7 @@
 	long int uSecs = howLong % 1000000;
 	unsigned int wSecs = howLong / 1000000;
 #else
-	long int uSecs = (__time_t)howLong % 1000000;
+	long int uSecs = (time_t)howLong % 1000000;
 	unsigned int wSecs = howLong / 1000000;
 #endif
 
@@ -145,7 +145,7 @@
 #ifdef _WIN32
 		sleeper.tv_sec = wSecs;
 #else
-		sleeper.tv_sec = (__time_t)wSecs;	
+		sleeper.tv_sec = (time_t)wSecs;	
 #endif
 		sleeper.tv_nsec = (long)(uSecs * 1000L);
 		nanosleep(&sleeper, NULL);