EINTR is now correctly handled in msg_send function by retry of
send operation.

Signed-off-by: Jan Friesse <[email protected]>
---
 branches/whitetank/exec/ipc.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/branches/whitetank/exec/ipc.c b/branches/whitetank/exec/ipc.c
index 17520c7..c97b466 100644
--- a/branches/whitetank/exec/ipc.c
+++ b/branches/whitetank/exec/ipc.c
@@ -1062,6 +1062,7 @@ void msg_send (void *conn, struct iovec *iov, int 
iov_len, int locked)
        }
 
        buf = !list_empty (&conn_info->outq_head);
+send_retry:
        res = send (conn_info->fd, &buf, 1, MSG_NOSIGNAL);
        if (res == -1 && errno == EAGAIN) {
                if (locked == 0) {
@@ -1073,6 +1074,8 @@ void msg_send (void *conn, struct iovec *iov, int 
iov_len, int locked)
                }
                poll_dispatch_modify (aisexec_poll_handle, conn_info->fd,
                        POLLIN|POLLOUT|POLLNVAL, poll_handler_connection);
+       } else if (res == -1 && errno == EINTR) {
+               goto send_retry;
        } else
        if (res == -1) {
                ipc_disconnect (conn_info);
-- 
1.7.4.1

_______________________________________________
Openais mailing list
[email protected]
https://lists.linux-foundation.org/mailman/listinfo/openais

Reply via email to