]> git.ipfire.org Git - thirdparty/lxc.git/commit
lxcapi_restore shouldn't steal the calling process
authorTycho Andersen <tycho.andersen@canonical.com>
Fri, 20 Mar 2015 16:17:31 +0000 (10:17 -0600)
committerStéphane Graber <stgraber@ubuntu.com>
Fri, 10 Apr 2015 15:29:08 +0000 (11:29 -0400)
commit8eed90689c8a562a82b68d373961d1708b3b6e94
treeee4a09120b6418c005d3965f829b843a70803a9e
parentf40960a3a3bb4a1a9433fe61a873b7ffc5e57db9
lxcapi_restore shouldn't steal the calling process

Previously, lxcapi_restore used the calling process as the lxc monitor process
(and just never returned), requiring users to fork before calling it. This, of
course, would cause problems for things like LXD, which can't fork.

Now, restore() forks the monitor as a child of the process that calls it. Users
who want to daemonize the restore process need to fork themselves.
lxc-checkpoint has been updated to reflect this behavior change.

Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com>
src/lxc/lxc_checkpoint.c
src/lxc/lxccontainer.c