MCPcopy Index your code
hub / github.com/tailscale/tailscale / setICMPEchoResponseCallback

Method setICMPEchoResponseCallback

wgengine/userspace.go:1522–1530  ·  view source on GitHub ↗
(idSeq uint32, cb func())

Source from the content-addressed store, hash-verified

1520}
1521
1522func (e *userspaceEngine) setICMPEchoResponseCallback(idSeq uint32, cb func()) {
1523 e.mu.Lock()
1524 defer e.mu.Unlock()
1525 if cb == nil {
1526 delete(e.icmpEchoResponseCallback, idSeq)
1527 } else {
1528 mak.Set(&e.icmpEchoResponseCallback, idSeq, cb)
1529 }
1530}
1531
1532// PeerForIP returns the Node in the wireguard config
1533// that's responsible for handling the given IP address.

Callers 1

sendICMPEchoRequestMethod · 0.95

Calls 3

SetFunction · 0.92
LockMethod · 0.65
UnlockMethod · 0.65

Tested by

no test coverage detected