Skip to content

Commit

Permalink
start: use lxc_raw_clone_cb() where possible
Browse files Browse the repository at this point in the history
This way we can rely on the kernel's copy-on-write support similar to fork().

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
  • Loading branch information
Christian Brauner committed Jan 1, 2018
1 parent 14c678f commit 66fe662
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lxc/start.c
Expand Up @@ -1380,7 +1380,7 @@ static int lxc_spawn(struct lxc_handler *handler)
flags &= ~CLONE_NEWNET;
}

handler->pid = lxc_clone(do_start, handler, flags);
handler->pid = lxc_raw_clone_cb(do_start, handler, flags);
if (handler->pid < 0) {
SYSERROR("Failed to clone a new set of namespaces.");
goto out_delete_net;
Expand Down

0 comments on commit 66fe662

Please sign in to comment.