Documentation ¶
Index ¶
Constants ¶
View Source
const SocketControlMessageBufferSize = unix.SizeofCmsghdr + (unix.SizeofInet6Pktinfo+unix.SizeofPtr-1) & ^(unix.SizeofPtr-1)
Variables ¶
This section is empty.
Functions ¶
func ParsePktinfoCmsg ¶
ParsePktinfoCmsg parses a single socket control message of type IP_PKTINFO or IPV6_PKTINFO, and returns the IP address and index of the network interface the packet was received from, or an error.
This function is only implemented for Linux, macOS and Windows. On other platforms, this is a no-op.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.