Skip to content

Commit ce70b8b

Browse files
committed
fix(sys/linux): EPoll_Data should only be packed on x86/x86_64
1 parent 8439141 commit ce70b8b

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

core/sys/linux/types.odin

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1446,9 +1446,16 @@ EPoll_Data :: struct #raw_union {
14461446
u64: u64,
14471447
}
14481448

1449-
EPoll_Event :: struct #packed {
1450-
events: EPoll_Event_Set,
1451-
data: EPoll_Data,
1449+
when ODIN_ARCH == .amd64 || ODIN_ARCH == .i386 {
1450+
EPoll_Event :: struct #packed {
1451+
events: EPoll_Event_Set,
1452+
data: EPoll_Data,
1453+
}
1454+
} else {
1455+
EPoll_Event :: struct {
1456+
events: EPoll_Event_Set,
1457+
data: EPoll_Data,
1458+
}
14521459
}
14531460

14541461
/*

0 commit comments

Comments
 (0)