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

Function ipPortOfNetstackAddr

wgengine/netstack/netstack.go:2150–2155  ·  view source on GitHub ↗
(a tcpip.Address, port uint16)

Source from the content-addressed store, hash-verified

2148}
2149
2150func ipPortOfNetstackAddr(a tcpip.Address, port uint16) (ipp netip.AddrPort, ok bool) {
2151 if addr, ok := netip.AddrFromSlice(a.AsSlice()); ok {
2152 return netip.AddrPortFrom(addr, port), true
2153 }
2154 return netip.AddrPort{}, false
2155}
2156
2157func readStatCounter(sc *tcpip.StatCounter) int64 {
2158 vv := sc.Value()

Callers 1

acceptUDPMethod · 0.85

Calls 1

AsSliceMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…