mirror of
https://github.com/containerd/containerd.git
synced 2026-11-07 22:06:45 +00:00
fixed epollwait on arm64
This commit is contained in:
1 parent
8641bebfde
commit
2fa44da736
1 file changed
+2
-2
@@ -61,9 +61,9 @@ func EpollCtl(epfd int, op int, fd int, event *syscall.EpollEvent) error {
|
||||
// EpollWait calls a C implementation
|
||||
func EpollWait(epfd int, events []syscall.EpollEvent, msec int) (int, error) {
|
||||
var c_events [128]C.struct_event_t
|
||||
n := int(C.run_epoll_wait(C.int(epfd), (*C.struct_event_t)(unsafe.Pointer(&c_events))))
|
||||
n, err := C.run_epoll_wait(C.int(epfd), (*C.struct_event_t)(unsafe.Pointer(&c_events)))
|
||||
if n < 0 {
|
||||
return int(n), fmt.Errorf("Failed to wait epoll")
|
||||
return int(n), err.(syscall.Errno)
|
||||
}
|
||||
for i := 0; i < n; i++ {
|
||||
events[i].Fd = int32(c_events[i].fd)
|
||||
|
||||
Reference in new issue
Block a user