diff --git a/src/stub.c b/src/stub.c index 4674356c..5d472f72 100644 --- a/src/stub.c +++ b/src/stub.c @@ -808,13 +808,8 @@ stub_tcp_write(int fd, getdns_tcp_state *tcp, getdns_network_req *netreq) /* Coming back from an earlier unfinished write or handshake. * Try to send remaining data */ -#ifdef USE_WINSOCK written = send(fd, (void *)(tcp->write_buf + tcp->written), tcp->write_buf_len - tcp->written, 0); -#else - written = write(fd, tcp->write_buf + tcp->written, - tcp->write_buf_len - tcp->written); -#endif if (written == -1) { if (_getdns_socketerror() == _getdns_EWOULDBLOCK) return STUB_TCP_WOULDBLOCK;