MCPcopy
hub / github.com/WireGuard/wireguard-go / ReceiveFunc

FuncType ReceiveFunc

conn/conn.go:28–28  ·  view source on GitHub ↗

A ReceiveFunc receives at least one packet from the network and writes them into packets. On a successful read it returns the number of elements of sizes, packets, and endpoints that should be evaluated. Some elements of sizes may be zero, and callers should ignore them. Callers must pass a sizes an

func(packets [][]byte, sizes []int, eps []Endpoint) (n int, err error)

Source from the content-addressed store, hash-verified

26// and eps slice with a length greater than or equal to the length of packets.
27// These lengths must not exceed the length of the associated Bind.BatchSize().
28type ReceiveFunc func(packets [][]byte, sizes []int, eps []Endpoint) (n int, err error)
29
30// A Bind listens on a port for both IPv6 and IPv4 UDP traffic.
31//

Callers 2

TestPrettyNameFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected