1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-26 04:35:39 +03:00
aports/testing/wiringx/fix_time_t.patch
Milan P. Stanić 88bd94eb29 testing/wiringx: new aport
https://github.com/wiringX/wiringX
modular approach to several GPIO interfaces
2019-12-24 21:16:58 +01:00

31 lines
929 B
Diff

--- 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);