Remove an erroneous check in the non-sendmmsg() version of g_socket_send_messages()

The docs specify that *all* errors are ignored if we managed to send
any data successfully, not just timeout/wouldblock.

https://bugzilla.gnome.org/show_bug.cgi?id=768549
This commit is contained in:
Dan Winship 2016-07-11 17:46:41 -04:00
parent 62bd8f54bb
commit e0bb25c214

View File

@ -4662,9 +4662,7 @@ g_socket_send_messages_with_timeout (GSocket *socket,
{
/* if we couldn't send all messages, just return how many we did
* manage to send, provided we managed to send at least one */
if (i > 0 &&
(g_error_matches (msg_error, G_IO_ERROR, G_IO_ERROR_WOULD_BLOCK) ||
g_error_matches (msg_error, G_IO_ERROR, G_IO_ERROR_TIMED_OUT)))
if (i > 0)
{
g_error_free (msg_error);
return i;