Commit 8d4b877a by Serge Hallyn

usernsexec: don't fail if we can't open pty

It's nice if we can do it, but not required. Exiting on this failure causes lxc-create started by root as a less-privileged userid to fail. Signed-off-by: 's avatarSerge Hallyn <serge.hallyn@ubuntu.com> Acked-by: 's avatarStéphane Graber <stgraber@ubuntu.com>
parent df2d4205
...@@ -76,9 +76,8 @@ static void opentty(const char * tty) { ...@@ -76,9 +76,8 @@ static void opentty(const char * tty) {
fd = open(tty, O_RDWR | O_NONBLOCK); fd = open(tty, O_RDWR | O_NONBLOCK);
if (fd == -1) { if (fd == -1) {
printf("FATAL: can't reopen tty: %s", strerror(errno)); printf("WARN: could not reopen tty: %s", strerror(errno));
sleep(1); return;
exit(1);
} }
flags = fcntl(fd, F_GETFL); flags = fcntl(fd, F_GETFL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment