1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

No need for a Container.networkManager field: it can be accessed via Container.runtime

This commit is contained in:
Solomon Hykes 2013-03-21 01:43:03 -07:00
parent 1ed13f65fe
commit d65983f386
2 changed files with 1 additions and 3 deletions

View file

@ -32,7 +32,6 @@ type Container struct {
Image string
network *NetworkInterface
networkManager *NetworkManager
NetworkSettings *NetworkSettings
SysInitPath string
@ -266,7 +265,7 @@ func (container *Container) StderrPipe() (io.ReadCloser, error) {
}
func (container *Container) allocateNetwork() error {
iface, err := container.networkManager.Allocate()
iface, err := container.runtime.networkManager.Allocate()
if err != nil {
return err
}

View file

@ -115,7 +115,6 @@ func (runtime *Runtime) Register(container *Container) error {
return err
}
container.runtime = runtime
container.networkManager = runtime.networkManager // FIXME: infer from docker.runtime
// Setup state lock (formerly in newState()
lock := new(sync.Mutex)
container.State.stateChangeLock = lock