Ignore "non-errors" when sending

h/t @f00bard

PUBLISHED_FROM=5deab05502797bb6393e8dbbd5684aba4a72a799
This commit is contained in:
Deomid Ryabkov 2016-04-22 16:19:46 +03:00 committed by rojer
parent c85edc38aa
commit 55398684cc

View File

@ -3313,6 +3313,7 @@ static void mg_write_to_socket(struct mg_connection *nc) {
{
n = (int) MG_SEND_FUNC(nc->sock, io->buf, io->len, 0);
DBG(("%p %d bytes -> %d", nc, n, nc->sock));
if (n < 0 && !mg_is_error(n)) return;
}
if (n > 0) {