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

network: fix a typo in udp cleanup path

Fix #3224 - Port already in use error when running a container

Signed-off-by: Tzu-Jung Lee <roylee17@gmail.com>
This commit is contained in:
Tzu-Jung Lee 2013-12-20 17:30:21 -08:00
parent aa619de748
commit 7d2e851d8e

View file

@ -628,7 +628,7 @@ func (iface *NetworkInterface) Release() {
log.Printf("Unable to release port %s", nat)
}
} else if nat.Port.Proto() == "udp" {
if err := iface.manager.tcpPortAllocator.Release(ip, hostPort); err != nil {
if err := iface.manager.udpPortAllocator.Release(ip, hostPort); err != nil {
log.Printf("Unable to release port %s: %s", nat, err)
}
}