Commit 32f4b9c7 by Serge Hallyn

coverity: close netns file when done

parent d966dd14
...@@ -1413,8 +1413,10 @@ static inline bool enter_to_ns(struct lxc_container *c) { ...@@ -1413,8 +1413,10 @@ static inline bool enter_to_ns(struct lxc_container *c) {
if (setns(netns, CLONE_NEWNET)) { if (setns(netns, CLONE_NEWNET)) {
SYSERROR("failed to setns for CLONE_NEWNET"); SYSERROR("failed to setns for CLONE_NEWNET");
close(netns);
goto out; goto out;
} }
close(netns);
return true; return true;
out: out:
return false; return false;
......
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