Skip to content

Conversation

@crosbymichael
Copy link
Member

Linux is not always not nil.
If Linux is nil, panic will occur.

Closes #1449

This is a rebase of #1449

Signed-off-by: Ma Shimiao [email protected]
Signed-off-by: Michael Crosby [email protected]

@mrunalp
Copy link
Contributor

mrunalp commented Aug 9, 2017

LGTM

Approved with PullApprove

func setupUserNamespace(spec *specs.Spec, config *configs.Config) error {
if len(spec.Linux.UIDMappings) == 0 {
return nil
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this removal seems unintended. i think if spec.Linux is nil here we shoud just bail to be the same as the old code.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The nil check should be on 613 now

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nvm, fixed it

Linux is not always not nil.
If Linux is nil, panic will occur.

Signed-off-by: Ma Shimiao <[email protected]>
Signed-off-by: Michael Crosby <[email protected]>
@cyphar
Copy link
Member

cyphar commented Aug 11, 2017

LGTM.

Approved with PullApprove

@hqhq
Copy link
Contributor

hqhq commented Aug 14, 2017

LGTM

Approved with PullApprove

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants