specconv: avoid skipping gidmappings applied when uidmappings is empty

Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
This commit is contained in:
Ma Shimiao 2017-11-30 16:21:28 +08:00
parent e8149af291
commit 57edfbbaf2
1 changed files with 0 additions and 3 deletions

View File

@ -618,9 +618,6 @@ func setupUserNamespace(spec *specs.Spec, config *configs.Config) error {
} }
} }
if spec.Linux != nil { if spec.Linux != nil {
if len(spec.Linux.UIDMappings) == 0 {
return nil
}
for _, m := range spec.Linux.UIDMappings { for _, m := range spec.Linux.UIDMappings {
config.UidMappings = append(config.UidMappings, create(m)) config.UidMappings = append(config.UidMappings, create(m))
} }