MCPcopy Create free account
hub / github.com/encodeous/nylon / Write

Method Write

polyamide/tun/tun.go:35–35  ·  view source on GitHub ↗

Write one or more packets to the device (without any additional headers). On a successful write it returns the number of packets written. A nonzero offset can be used to instruct the Device on where to begin writing from each packet contained within the bufs slice.

(bufs [][]byte, offset int)

Source from the content-addressed store, hash-verified

33 // offset can be used to instruct the Device on where to begin writing from
34 // each packet contained within the bufs slice.
35 Write(bufs [][]byte, offset int) (int, error)
36
37 // MTU returns the MTU of the Device.
38 MTU() (int, error)

Callers 15

routineHackListenerMethod · 0.65
WriteMethod · 0.65
WriteMethod · 0.65
WriteMethod · 0.65
WriteMethod · 0.65
WriteToMethod · 0.65
dnsPacketRoundTripFunction · 0.65
dnsStreamRoundTripFunction · 0.65
mainFunction · 0.65
WriteMethod · 0.65
CancelMethod · 0.65

Implementers 4

NativeTunpolyamide/tun/tun_linux.go
netTunpolyamide/tun/netstack/tun.go
chTunpolyamide/tun/tuntest/tuntest.go
fakeTUNDeviceSizedpolyamide/device/device_test.go

Calls

no outgoing calls

Tested by 6

TestNoiseHandshakeFunction · 0.52
TestPingPongFunction · 0.52
TestTimeoutPendingWriteFunction · 0.52
TestEchoWithMessagingFunction · 0.52
TestMessageReadModeFunction · 0.52