Skip to content

Commit

Permalink
Merge pull request moby#16041 from runcom/portmapping-doc-cleaning
Browse files Browse the repository at this point in the history
Clean latest api doc from PortMapping and outdated error check
  • Loading branch information
tiborvass committed Sep 3, 2015
2 parents 9b072fb + 137c12f commit 2d605ce
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions daemon/container.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"io/ioutil"
"os"
"path/filepath"
"strings"
"sync"
"syscall"
"time"
Expand Down Expand Up @@ -105,8 +104,7 @@ func (container *Container) fromDisk() error {
dec := json.NewDecoder(jsonSource)

// Load container settings
// udp broke compat of docker.PortMapping, but it's not used when loading a container, we can skip it
if err := dec.Decode(container); err != nil && !strings.Contains(err.Error(), "docker.PortMapping") {
if err := dec.Decode(container); err != nil {
return err
}

Expand Down
4 changes: 1 addition & 3 deletions docs/reference/api/docker_remote_api_v1.21.md
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,6 @@ Return low-level information on the container `id`
"IPAddress": "",
"IPPrefixLen": 0,
"MacAddress": "",
"PortMapping": null,
"Ports": null
},
"Path": "/bin/sh",
Expand Down Expand Up @@ -2244,7 +2243,6 @@ Return low-level information about the `exec` command `id`.
"MacAddress" : "02:42:ac:11:00:02",
"Gateway" : "172.17.42.1",
"Bridge" : "docker0",
"PortMapping" : null,
"Ports" : {}
},
"ResolvConfPath" : "/var/lib/docker/containers/8f177a186b977fb451136e0fdf182abff5599a08b3c7f6ef0d36a55aaf89634c/resolv.conf",
Expand All @@ -2258,7 +2256,7 @@ Return low-level information about the `exec` command `id`.
"ProcessLabel" : "",
"AppArmorProfile" : "",
"RestartCount" : 0,
"Mounts" : [],
"Mounts" : []
}
}

Expand Down

0 comments on commit 2d605ce

Please sign in to comment.