Commit 3821b342 authored by Cyrill Gorcunov's avatar Cyrill Gorcunov Committed by Andrei Vagin

scm: Unweave fds mess

Currently criu built with criu/pie-util-fd (which
is a symlink to criu/pie/util-fd) with same flags
as we use in general compel infection code. Moreover
the criu link with libcompel.a, so we get a problem
where send_fds/recv_fds are multiple defined. Lets
rather unweave this mess:

 - drop criu/pie-util-fd.c completely
 - move send_fd/recv_fd inliners into scm.h
Signed-off-by: 's avatarCyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
Signed-off-by: 's avatarAndrei Vagin <avagin@virtuozzo.com>
parent fa6243b6
......@@ -9,9 +9,4 @@
#include "common/scm.h"
static inline int send_fd(int sock, struct sockaddr_un *saddr, int saddr_len, int fd)
{
return send_fds(sock, saddr, saddr_len, &fd, 1, false);
}
#endif /* __COMPEL_PLUGIN_FDS_H__ */
......@@ -27,6 +27,15 @@
#include "infect-priv.h"
#include "infect-util.h"
#include "rpc-pie-priv.h"
#include "infect-util.h"
#define __sys(foo) foo
#define __memcpy memcpy
#define SCM_FDSET_HAS_OPTS
#include "common/scm.h"
#include "common/scm-code.c"
#define UNIX_PATH_MAX (sizeof(struct sockaddr_un) - \
(size_t)((struct sockaddr_un *) 0)->sun_path)
......
......@@ -47,7 +47,6 @@ obj-y += page-pipe.o
obj-y += pagemap.o
obj-y += page-xfer.o
obj-y += parasite-syscall.o
obj-y += pie-util-fd.o
obj-y += pie-util.o
obj-y += pipes.o
obj-y += plugin.o
......
pie/util-fd.c
\ No newline at end of file
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