goto out_close;
}
- ret = recv(fd, reqdata, req.datalen, 0);
+ ret = lxc_recv_nointr(fd, reqdata, req.datalen, 0);
if (ret != req.datalen) {
WARN("Failed to receive full command request. Ignoring "
"request for \"%s\"", lxc_cmd_str(req.cmd));
#include "commands.h"
#include "commands_utils.h"
#include "initutils.h"
+#include "file_utils.h"
#include "log.h"
#include "lxclock.h"
#include "monitor.h"
memset(&msg, 0, sizeof(msg));
-again:
- ret = recv(state_client_fd, &msg, sizeof(msg), 0);
+ ret = lxc_recv_nointr(state_client_fd, &msg, sizeof(msg), 0);
if (ret < 0) {
- if (errno == EINTR) {
- TRACE("Caught EINTR; retrying");
- goto again;
- }
-
SYSERROR("Failed to receive message");
return -1;
}
#include "af_unix.h"
#include "conf.h"
#include "config.h"
+#include "file_utils.h"
#include "log.h"
#include "macro.h"
#include "network.h"
if (netdev->type != LXC_NET_VETH)
continue;
- ret = recv(data_sock, netdev->name, IFNAMSIZ, 0);
+ ret = lxc_recv_nointr(data_sock, netdev->name, IFNAMSIZ, 0);
if (ret < 0)
return -1;
TRACE("Received network device name \"%s\" from parent", netdev->name);
/* Receive network device name in the child's namespace to
* parent.
*/
- ret = recv(data_sock, netdev->name, IFNAMSIZ, 0);
+ ret = lxc_recv_nointr(data_sock, netdev->name, IFNAMSIZ, 0);
if (ret < 0)
return -1;
/* Receive network device ifindex in the child's namespace to
* parent.
*/
- ret = recv(data_sock, &netdev->ifindex, sizeof(netdev->ifindex), 0);
+ ret = lxc_recv_nointr(data_sock, &netdev->ifindex, sizeof(netdev->ifindex), 0);
if (ret < 0)
return -1;
}