MCPcopy Create free account
hub / github.com/pion/ice / WriteTo

Method WriteTo

renomination_test.go:35–43  ·  view source on GitHub ↗
(b []byte, addr net.Addr)

Source from the content-addressed store, hash-verified

33}
34
35func (m *mockPacketConnWithCapture) WriteTo(b []byte, addr net.Addr) (n int, err error) {
36 // Capture the packet
37 packet := make([]byte, len(b))
38 copy(packet, b)
39 m.sentPackets = append(m.sentPackets, packet)
40 m.sentAddrs = append(m.sentAddrs, addr)
41
42 return len(b), nil
43}
44
45func (m *mockPacketConnWithCapture) Close() error { return nil }
46func (m *mockPacketConnWithCapture) LocalAddr() net.Addr { return nil }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected