File tree Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -253,11 +253,7 @@ public final class ConditionLock<T: Equatable> {
253253 gettimeofday ( & curTime, nil )
254254
255255 let allNSecs : Int64 = timeoutNS + Int64( curTime. tv_usec) * 1000
256- #if canImport(wasi_pthread)
257- let tvSec = curTime. tv_sec + ( allNSecs / nsecPerSec)
258- #else
259- let tvSec = curTime. tv_sec + Int( ( allNSecs / nsecPerSec) )
260- #endif
256+ let tvSec = curTime. tv_sec + time_t( ( allNSecs / nsecPerSec) )
261257
262258 var timeoutAbs = timespec (
263259 tv_sec: tvSec,
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ extension timespec {
4646 let nsecPerSec : Int64 = 1_000_000_000
4747 let ns = amount. nanoseconds
4848 let sec = ns / nsecPerSec
49- self = timespec ( tv_sec: Int ( sec) , tv_nsec: Int ( ns - sec * nsecPerSec) )
49+ self = timespec ( tv_sec: time_t ( sec) , tv_nsec: Int ( ns - sec * nsecPerSec) )
5050 }
5151}
5252#endif
You can’t perform that action at this time.
0 commit comments