instead of just returning
with error.
It seems to me that fd's are not passed to lxc-init.
--
Best regards, Vladimir Smirnov.
From bfdbefce2561134d5fd3d67a2047dc205b6e0974 Mon Sep 17 00:00:00 2001
From: Vladimir Smirnov
Date: Mon, 22 Aug 2011 15:14:07 +0400
Subject: [PATCH 1/2] Modify l
Patch in attach changes lxc-start to set CLOEXEC instead of just
returning with error.
--
Best Regards, Vladimir Smirnov.
From 60588293338576adc086e5f507cf86732439bfa5 Mon Sep 17 00:00:00 2001
From: Vladimir Smirnov
Date: Mon, 22 Aug 2011 15:16:18 +0400
Subject: [PATCH 2/2] lxc-start shouldn
Patch in attachment changes lxc-init and lxc-attach to use clone instead
of fork.
Reason for it: clone permits to set custom flags, so you can call it
without CLONE_FILES and all fd's with O_CLOEXEC flag won't be passed to
child.
--
Best regards, Vladimir Smir
Previous patch fixed behaviour with clone, so it's now safe just to set
O_CLOEXEC flag on
all inherited fd's.
Signed-off-by: Vladimir Smirnov
---
src/lxc/start.c | 15 +--
1 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/src/lxc/start.c b/src/lxc/sta
Clone allows more flexible control. Currently, if there is any inherited fd,
lxc-start exits with error. With clone it's possible not to pass open fd's to
childs.
Signed-off-by: Vladimir Smirnov
---
src/lxc/lxc_attach.c | 79 +