MCPcopy
hub / github.com/google/gvisor / GetNetworkConfig

Method GetNetworkConfig

runsc/boot/controller.go:1260–1272  ·  view source on GitHub ↗

GetNetworkConfig returns the network interfaces and routes.

(_ *struct{}, networkArgs *CreateLinksAndRoutesArgs)

Source from the content-addressed store, hash-verified

1258
1259// GetNetworkConfig returns the network interfaces and routes.
1260func (cm *containerManager) GetNetworkConfig(_ *struct{}, networkArgs *CreateLinksAndRoutesArgs) error {
1261 log.Debugf("containerManager.GetNetworkConfig")
1262 cm.l.mu.Lock()
1263 if cm.l.networkArgs != nil {
1264 *networkArgs = *cm.l.networkArgs
1265 }
1266 cm.l.mu.Unlock()
1267
1268 if networkArgs == nil {
1269 log.Debugf("networks args is nil")
1270 }
1271 return nil
1272}

Callers 1

TestNetworkConfigFunction · 0.45

Calls 3

DebugfFunction · 0.92
LockMethod · 0.65
UnlockMethod · 0.65

Tested by 1

TestNetworkConfigFunction · 0.36