Commit c07085a9 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Reallow file descriptor above FD_SETSIZE since we now use poll()

parent ad3d32f6
......@@ -79,14 +79,6 @@ int net_Socket( vlc_object_t *p_this, int i_family, int i_socktype,
msg_Err( p_this, "cannot set socket to non-blocking mode" );
}
#else
if( fd >= FD_SETSIZE )
{
/* We don't want to overflow select() fd_set */
msg_Err( p_this, "cannot create socket (too many already in use)" );
net_Close( fd );
return -1;
}
fcntl( fd, F_SETFD, FD_CLOEXEC );
i_val = fcntl( fd, F_GETFL, 0 );
fcntl( fd, F_SETFL, ((i_val != -1) ? i_val : 0) | O_NONBLOCK );
......
......@@ -416,13 +416,6 @@ int __net_Accept( vlc_object_t *p_this, int *pi_fd, mtime_t i_wait )
if( i_val < 0 )
msg_Err( p_this, "accept failed (%s)",
net_strerror( net_errno ) );
#ifndef WIN32
else if( i_val >= FD_SETSIZE )
{
net_Close( i_val ); /* avoid future overflows in FD_SET */
msg_Err( p_this, "accept failed (too many sockets opened)" );
}
#endif
else
{
const int yes = 1;
......
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