From: Serge Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
To: containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org
Subject: [PATCH 2/3] ignore -eexist for mkdir of a cgroup
Date: Mon, 15 Feb 2010 16:58:15 -0600 [thread overview]
Message-ID: <1266274696-23018-3-git-send-email-serue@us.ibm.com> (raw)
In-Reply-To: <1266274696-23018-1-git-send-email-serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
From: Serge E. Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
Signed-off-by: Serge E. Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
---
nsexec.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/nsexec.c b/nsexec.c
index 859b6c3..8b96bc9 100644
--- a/nsexec.c
+++ b/nsexec.c
@@ -146,7 +146,7 @@ int move_to_new_cgroup(int newcgroup)
snprintf(cgroupname, 150, "%s/%d", cgroupbase, newcgroup);
ret = mkdir(cgroupname, 0755);
- if (ret)
+ if (ret && errno != EEXIST)
return 0;
snprintf(tasksfname, 200, "%s/tasks", cgroupname);
fout = fopen(tasksfname, "w");
--
1.6.0.6
next prev parent reply other threads:[~2010-02-15 22:58 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-15 22:58 (unknown), Serge Hallyn
[not found] ` <1266274696-23018-1-git-send-email-serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2010-02-15 22:58 ` [PATCH 1/3] rename and install nsexec Serge Hallyn
2010-02-15 22:58 ` Serge Hallyn [this message]
2010-02-15 22:58 ` [PATCH 3/3] nsexec: remount proc and devpts Serge Hallyn
[not found] ` <1266274696-23018-4-git-send-email-serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2010-02-16 11:38 ` Michael Tokarev
[not found] ` <4B7A83CB.4070009-Gdu+ltImwkhes2APU0mLOQ@public.gmane.org>
2010-02-16 14:19 ` Serge E. Hallyn
2010-02-16 0:35 ` your mail Matt Helsley
[not found] ` <20100216003531.GL3714-52DBMbEzqgQ/wnmkkaCWp/UQ3DHhIser@public.gmane.org>
2010-02-16 19:04 ` Sukadev Bhattiprolu
2010-02-16 9:26 ` Oren Laadan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1266274696-23018-3-git-send-email-serue@us.ibm.com \
--to=serue-r/jw6+rmf7hqt0dzr+alfa@public.gmane.org \
--cc=containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.