Unverified Commit b49f36bc by Stéphane Graber Committed by GitHub

Merge pull request #3700 from brauner/2021-02-26/fixes_2

small fixes
parents 88e27cd6 cfe6f435
...@@ -182,6 +182,12 @@ static ssize_t lxc_abstract_unix_recv_fds_iov(int fd, ...@@ -182,6 +182,12 @@ static ssize_t lxc_abstract_unix_recv_fds_iov(int fd,
if (hweight32((ret_fds->flags & ~UNIX_FDS_ACCEPT_NONE)) > 1) if (hweight32((ret_fds->flags & ~UNIX_FDS_ACCEPT_NONE)) > 1)
return ret_errno(EINVAL); return ret_errno(EINVAL);
if (ret_fds->fd_count_max >= KERNEL_SCM_MAX_FD)
return ret_errno(EINVAL);
if (ret_fds->fd_count_ret != 0)
return ret_errno(EINVAL);
cmsgbuf = zalloc(cmsgbufsize); cmsgbuf = zalloc(cmsgbufsize);
if (!cmsgbuf) if (!cmsgbuf)
return ret_errno(ENOMEM); return ret_errno(ENOMEM);
......
...@@ -1239,7 +1239,7 @@ static int do_start(void *data) ...@@ -1239,7 +1239,7 @@ static int do_start(void *data)
} }
ret = setns(timens_fd, CLONE_NEWTIME); ret = setns(timens_fd, CLONE_NEWTIME);
if (ret) { if (ret) {
SYSERROR("Failed to setns(%d(\"/proc/self/ns/time_for_children\"))", timens_fd); SYSERROR("Failed to setns(%d(\"/proc/self/ns/time_for_children\"))", timens_fd);
goto out_warn_father; goto out_warn_father;
} }
......
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