github.com/mikelsr/quic-go@v0.36.1-0.20230701132136-1d9415b66898/sys_conn_helper_darwin.go (about)

     1  //go:build darwin
     2  
     3  package quic
     4  
     5  import "golang.org/x/sys/unix"
     6  
     7  const (
     8  	msgTypeIPTOS = unix.IP_RECVTOS
     9  	ipv4PKTINFO  = unix.IP_RECVPKTINFO
    10  )
    11  
    12  // ReadBatch only returns a single packet on OSX,
    13  // see https://godoc.org/golang.org/x/net/ipv4#PacketConn.ReadBatch.
    14  const batchSize = 1