From 224999d9c21dc6d1d9aa43fb364ded09726e1d56 Mon Sep 17 00:00:00 2001 From: Blake Geno Date: Tue, 4 Nov 2014 18:53:34 -0500 Subject: [PATCH 1/2] made getDefaultNetworkMtu private Signed-off-by: Blake Geno --- daemon/config.go | 2 +- daemon/daemon.go | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/daemon/config.go b/daemon/config.go index 9e8d08e2a6..ddb6040bff 100644 --- a/daemon/config.go +++ b/daemon/config.go @@ -70,7 +70,7 @@ func (config *Config) InstallFlags() { opts.MirrorListVar(&config.Mirrors, []string{"-registry-mirror"}, "Specify a preferred Docker registry mirror") } -func GetDefaultNetworkMtu() int { +func getDefaultNetworkMtu() int { if iface, err := networkdriver.GetDefaultRouteIface(); err == nil { return iface.MTU } diff --git a/daemon/daemon.go b/daemon/daemon.go index 084d779033..b0feae917b 100644 --- a/daemon/daemon.go +++ b/daemon/daemon.go @@ -721,8 +721,7 @@ func NewDaemon(config *Config, eng *engine.Engine) (*Daemon, error) { func NewDaemonFromDirectory(config *Config, eng *engine.Engine) (*Daemon, error) { // Apply configuration defaults if config.Mtu == 0 { - // FIXME: GetDefaultNetwork Mtu doesn't need to be public anymore - config.Mtu = GetDefaultNetworkMtu() + config.Mtu = getDefaultNetworkMtu() } // Check for mutually incompatible config options if config.BridgeIface != "" && config.BridgeIP != "" { From cbb88741e40315c5e92f2be92faedc178cf32d1c Mon Sep 17 00:00:00 2001 From: Blake Geno Date: Wed, 5 Nov 2014 08:36:08 -0500 Subject: [PATCH 2/2] Removed fixme from utils_test.go Signed-off-by: Blake Geno --- integration/utils_test.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/integration/utils_test.go b/integration/utils_test.go index 1d6e3ec609..da20de586c 100644 --- a/integration/utils_test.go +++ b/integration/utils_test.go @@ -37,10 +37,6 @@ type Fataler interface { func mkDaemon(f Fataler) *daemon.Daemon { eng := newTestEngine(f, false, "") return mkDaemonFromEngine(eng, f) - // FIXME: - // [...] - // Mtu: docker.GetDefaultNetworkMtu(), - // [...] } func createNamedTestContainer(eng *engine.Engine, config *runconfig.Config, f Fataler, name string) (shortId string) {