Branch: refs/heads/master
Home: https://github.com/lxc/lxc
Commit: 6c6892b5c5c6281d1e74c979168d1cbbe6a50ffc
https://github.com/lxc/lxc/commit/6c6892b5c5c6281d1e74c979168d1cbbe6a50ffc
Author: Dwight Engen <dwight.en...@oracle.com>
Date: 2013-11-12 (Tue, 12 Nov 2013)
Changed paths:
M src/lxc/lxccontainer.c
Log Message:
-----------
fix multithreaded create()
We were calling save_config() twice within the create() flow, each
from a different process. Depending on order of scheduling, sometimes
the data from the first save_config() (which was just the stuff from
LXC_DEFAULT_CONFIG) would overwrite the config we wanted (the full
config), causing a truncated config file which would then cause lxc
to segfault once it read it back in because no rootfs.path was set.
This fixes it by only calling save_config() once in the create()
flow. A rejected alternative was to call fsync(fileno(fout)) before
the fclose in save_config.
Signed-off-by: Dwight Engen <dwight.en...@oracle.com>
Acked-by: S.Çağlar Onur <cag...@10ur.org>
Signed-off-by: Serge Hallyn <serge.hal...@ubuntu.com>
Commit: 68c9cf36681cf0cdec6725b513107f9b65273498
https://github.com/lxc/lxc/commit/68c9cf36681cf0cdec6725b513107f9b65273498
Author: Dwight Engen <dwight.en...@oracle.com>
Date: 2013-11-12 (Tue, 12 Nov 2013)
Changed paths:
M src/lxc/lxccontainer.c
Log Message:
-----------
add process_lock()/unlock() in save_config()
This is likely unnecessary, but is consistent with other uses of
fopen()/fclose() in lxc.
Signed-off-by: Dwight Engen <dwight.en...@oracle.com>
Acked-by: S.Çağlar Onur <cag...@10ur.org>
Signed-off-by: Serge Hallyn <serge.hal...@ubuntu.com>
Compare: https://github.com/lxc/lxc/compare/bdb3f44147bc...68c9cf36681c
------------------------------------------------------------------------------
DreamFactory - Open Source REST & JSON Services for HTML5 & Native Apps
OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
Free app hosting. Or install the open source package on any LAMP server.
Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
http://pubads.g.doubleclick.net/gampad/clk?id=63469471&iu=/4140/ostg.clktrk
_______________________________________________
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel