[sys/linux]: Fix epoll_wait on arm64

This commit is contained in:
flysand7
2023-12-06 00:09:10 +11:00
parent 03282c1234
commit cb66ed52ce

View File

@@ -2411,7 +2411,11 @@ epoll_wait :: proc(epfd: Fd, events: [^]EPoll_Event, count: i32, timeout: i32) -
return errno_unwrap(ret, i32)
} else {
// Convert milliseconds to nanosecond timespec
ret := syscall(SYS_epoll_pwait, epfd, events, count, timeout, nil)
timeout_ns := Time_Spec {
time_sec = timeout * 1000,
time_nsec = 0,
}
ret := syscall(SYS_epoll_pwait, epfd, events, count, &timeout_ns, rawptr(nil))
return errno_unwrap(ret, i32)
}
}