2021-11-10 18:45:26 +00:00
|
|
|
//go:build darwin
|
2021-08-03 09:04:02 +00:00
|
|
|
// +build darwin
|
|
|
|
|
|
|
|
package quic
|
|
|
|
|
|
|
|
import "golang.org/x/sys/unix"
|
|
|
|
|
2021-11-10 18:45:26 +00:00
|
|
|
const (
|
|
|
|
msgTypeIPTOS = unix.IP_RECVTOS
|
|
|
|
disablePathMTUDiscovery = false
|
|
|
|
)
|
2021-08-03 09:04:02 +00:00
|
|
|
|
|
|
|
const (
|
|
|
|
ipv4RECVPKTINFO = unix.IP_RECVPKTINFO
|
|
|
|
ipv6RECVPKTINFO = 0x3d
|
|
|
|
)
|
|
|
|
|
|
|
|
const (
|
|
|
|
msgTypeIPv4PKTINFO = unix.IP_PKTINFO
|
|
|
|
msgTypeIPv6PKTINFO = 0x2e
|
|
|
|
)
|
2021-08-27 11:26:00 +00:00
|
|
|
|
|
|
|
// ReadBatch only returns a single packet on OSX,
|
|
|
|
// see https://godoc.org/golang.org/x/net/ipv4#PacketConn.ReadBatch.
|
|
|
|
const batchSize = 1
|