Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

`r.destroy` can defer exec in `runner.run` method. #2038

Merged
merged 1 commit into from May 7, 2019

Conversation

Projects
None yet
4 participants
@imxyb
Copy link
Contributor

commented Apr 10, 2019

Signed-off-by: Xiao YongBiao xyb4638@gmail.com

`r.destroy` can defer exec in `runner.run` method.
Signed-off-by: Xiao YongBiao <xyb4638@gmail.com>
@imxyb

This comment has been minimized.

Copy link
Contributor Author

commented Apr 11, 2019

@caniszczyk @cyphar PTAL, thanks!

@crosbymichael

This comment has been minimized.

Copy link
Member

commented Apr 11, 2019

LGTM

Approved with PullApprove

1 similar comment
@mrunalp

This comment has been minimized.

Copy link
Contributor

commented May 7, 2019

LGTM

Approved with PullApprove

@mrunalp mrunalp merged commit eb4aeed into opencontainers:master May 7, 2019

3 checks passed

DCO DCO
Details
code-review/pullapprove Approved by crosbymichael, mrunalp
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@@ -266,13 +266,17 @@ type runner struct {
}

func (r *runner) run(config *specs.Process) (int, error) {

This comment has been minimized.

Copy link
@cyphar

cyphar May 7, 2019

Member

The correct way of handling this would've been to use (_ int, Err error) and then using the error in the defer. Otherwise, if you have a return -1, fmt.Errorf() you will treat it as a nil.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.