|
|
@ -146,8 +146,7 @@ rfbInitSockets(rfbScreenInfoPtr rfbScreen)
|
|
|
|
|
|
|
|
|
|
|
|
if (setsockopt(rfbScreen->inetdSock, IPPROTO_TCP, TCP_NODELAY,
|
|
|
|
if (setsockopt(rfbScreen->inetdSock, IPPROTO_TCP, TCP_NODELAY,
|
|
|
|
(char *)&one, sizeof(one)) < 0) {
|
|
|
|
(char *)&one, sizeof(one)) < 0) {
|
|
|
|
rfbLogPerror("setsockopt");
|
|
|
|
rfbLogPerror("setsockopt failed: can't set TCP_NODELAY flag, non TCP socket?");
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
FD_ZERO(&(rfbScreen->allFds));
|
|
|
|
FD_ZERO(&(rfbScreen->allFds));
|
|
|
@ -453,9 +452,7 @@ rfbProcessNewConnection(rfbScreenInfoPtr rfbScreen)
|
|
|
|
|
|
|
|
|
|
|
|
if (setsockopt(sock, IPPROTO_TCP, TCP_NODELAY,
|
|
|
|
if (setsockopt(sock, IPPROTO_TCP, TCP_NODELAY,
|
|
|
|
(char *)&one, sizeof(one)) < 0) {
|
|
|
|
(char *)&one, sizeof(one)) < 0) {
|
|
|
|
rfbLogPerror("rfbCheckFds: setsockopt");
|
|
|
|
rfbLogPerror("rfbCheckFds: setsockopt failed: can't set TCP_NODELAY flag, non TCP socket?");
|
|
|
|
closesocket(sock);
|
|
|
|
|
|
|
|
return FALSE;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
#ifdef USE_LIBWRAP
|
|
|
|
#ifdef USE_LIBWRAP
|
|
|
@ -556,9 +553,7 @@ rfbConnect(rfbScreenInfoPtr rfbScreen,
|
|
|
|
|
|
|
|
|
|
|
|
if (setsockopt(sock, IPPROTO_TCP, TCP_NODELAY,
|
|
|
|
if (setsockopt(sock, IPPROTO_TCP, TCP_NODELAY,
|
|
|
|
(char *)&one, sizeof(one)) < 0) {
|
|
|
|
(char *)&one, sizeof(one)) < 0) {
|
|
|
|
rfbLogPerror("setsockopt failed");
|
|
|
|
rfbLogPerror("setsockopt failed: can't set TCP_NODELAY flag, non TCP socket?");
|
|
|
|
closesocket(sock);
|
|
|
|
|
|
|
|
return -1;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/* AddEnabledDevice(sock); */
|
|
|
|
/* AddEnabledDevice(sock); */
|
|
|
|