diff --git a/unix/types_linux.go b/unix/types_linux.go index 9a8d2b6f..abc5e5d7 100644 --- a/unix/types_linux.go +++ b/unix/types_linux.go @@ -55,6 +55,8 @@ package unix #include #include #include +#include +#include #ifdef TCSETS2 // On systems that have "struct termios2" use this as type Termios. diff --git a/unix/ztypes_linux_386.go b/unix/ztypes_linux_386.go index 72c7f091..fb1257ae 100644 --- a/unix/ztypes_linux_386.go +++ b/unix/ztypes_linux_386.go @@ -151,6 +151,15 @@ type Flock_t struct { Pid int32 } +const ( + FADV_NORMAL = 0x0 + FADV_RANDOM = 0x1 + FADV_SEQUENTIAL = 0x2 + FADV_WILLNEED = 0x3 + FADV_DONTNEED = 0x4 + FADV_NOREUSE = 0x5 +) + type RawSockaddrInet4 struct { Family uint16 Port uint16 diff --git a/unix/ztypes_linux_amd64.go b/unix/ztypes_linux_amd64.go index 70a443f4..34edb368 100644 --- a/unix/ztypes_linux_amd64.go +++ b/unix/ztypes_linux_amd64.go @@ -153,6 +153,15 @@ type Flock_t struct { Pad_cgo_1 [4]byte } +const ( + FADV_NORMAL = 0x0 + FADV_RANDOM = 0x1 + FADV_SEQUENTIAL = 0x2 + FADV_WILLNEED = 0x3 + FADV_DONTNEED = 0x4 + FADV_NOREUSE = 0x5 +) + type RawSockaddrInet4 struct { Family uint16 Port uint16