From 4b360d63009f3879ec0e17eee9808cf7823018ee Mon Sep 17 00:00:00 2001 From: xlgao-zju Date: Mon, 5 Oct 2015 01:11:48 +0800 Subject: [PATCH] change uid to gid in func HostGID Signed-off-by: xlgao-zju --- libcontainer/configs/config_unix.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libcontainer/configs/config_unix.go b/libcontainer/configs/config_unix.go index 89f580bf..c447f3ef 100644 --- a/libcontainer/configs/config_unix.go +++ b/libcontainer/configs/config_unix.go @@ -21,7 +21,7 @@ func (c Config) HostUID() (int, error) { return 0, nil } -// Gets the root uid for the process on host which could be non-zero +// Gets the root gid for the process on host which could be non-zero // when user namespaces are enabled. func (c Config) HostGID() (int, error) { if c.Namespaces.Contains(NEWUSER) { @@ -30,11 +30,11 @@ func (c Config) HostGID() (int, error) { } id, found := c.hostIDFromMapping(0, c.GidMappings) if !found { - return -1, fmt.Errorf("User namespaces enabled, but no root user mapping found.") + return -1, fmt.Errorf("User namespaces enabled, but no root group mapping found.") } return id, nil } - // Return default root uid 0 + // Return default root gid 0 return 0, nil }