Commit 935d15d0 authored by Youness Alaoui's avatar Youness Alaoui Committed by Olivier Crête

Return number of sent messages in socket_send_messages when an error happens part-way

parent 39a65a1d
......@@ -342,6 +342,8 @@ socket_send_messages (NiceSocket *sock, const NiceAddress *to,
if (len < 0) {
/* Error. */
if (i > 0)
break;
return len;
} else if (len == 0) {
/* EWOULDBLOCK. */
......
......@@ -300,6 +300,8 @@ socket_send_messages (NiceSocket *sock, const NiceAddress *to,
if (len < 0) {
/* Error. */
if (i > 0)
break;
return len;
} else if (len == 0) {
/* EWOULDBLOCK. */
......
......@@ -759,6 +759,8 @@ socket_send_messages (NiceSocket *sock, const NiceAddress *to,
if (len < 0) {
/* Error. */
if (i > 0)
break;
return len;
} else if (len == 0) {
/* EWOULDBLOCK. */
......
......@@ -281,6 +281,8 @@ socket_send_messages (NiceSocket *sock, const NiceAddress *to,
if (len < 0) {
/* Error. */
if (i > 0)
break;
return len;
} else if (len == 0) {
/* EWOULDBLOCK. */
......
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