int ret = 0;
while(cursor) {
int fd = (int)cursor->data;
+ pthread_mutex_unlock(&ipc_svc->subscribe_fds_mutex);
ret = socket_send(fd, buf, length);
if (ret < 0) {
ERROR("socket_send publish error : %d", ret);
ERROR("socket_send_data publish error : %d", ret);
}
}
+ pthread_mutex_lock(&ipc_svc->subscribe_fds_mutex);
cursor = g_list_next(cursor);
}
pthread_mutex_unlock(&ipc_svc->subscribe_fds_mutex);
while (length > 0) {
passed_len = send(fd, (const void *)buf, length, MSG_NOSIGNAL);
if (passed_len == -1) {
- if (errno == EINTR)
+ if (errno == EINTR){
+ ERROR("EINTR error. send retry");
continue;
- else if (errno == EAGAIN)
+ }
+ else if (errno == EAGAIN) {
+ ERROR("EAGAIN error. send retry");
continue;
- else if (errno == EWOULDBLOCK)
+ }
+ else if (errno == EWOULDBLOCK) {
+ ERROR("EWOULDBLOCK error. send retry");
continue;
+ }
ERROR("send error [%d]", errno);
break;
} else if (passed_len == 0)