attach: use correct put method

Fixes: Coverity 1472763 Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent 5e6b9c8a
...@@ -1321,7 +1321,7 @@ int lxc_attach(struct lxc_container *container, lxc_attach_exec_t exec_function, ...@@ -1321,7 +1321,7 @@ int lxc_attach(struct lxc_container *container, lxc_attach_exec_t exec_function,
ret = get_attach_context_nsfds(ctx, options); ret = get_attach_context_nsfds(ctx, options);
if (ret) { if (ret) {
lxc_container_put(container); put_attach_context(ctx);
return log_error(-1, "Failed to get namespace file descriptors"); return log_error(-1, "Failed to get namespace file descriptors");
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment