This is listed in Trac under #2022 ,
http://trac.videolan.org/vlc/ticket/2022
Caused by windows recv call returning -1 (and WSAEWOULDBLOCK via WSAGetLastError() ) if there is no data waiting for it. WinSock would prefer you to use select() calls to poll a socket for data I guess. There are several ways to work around this, easiest would be making the accepted socket blocking
Not entirely sure what that would break though.
So fixing the unwanted Block error is probably better. Open file modules/control/telnet.c . Locate line
Code: Select all
if (i_recv <= 0 && ( end || errno != EAGAIN ) ) {
Insert *above* that:
Code: Select all
#ifdef WIN32
if (i_recv <= 0 && WSAGetLastError() == WSAEWOULDBLOCK ) {
errno=EAGAIN;
}
#endif
Insert near top of the telnet.c file:
Code: Select all
#ifdef WIN32
#include "winsock2.h"
#endif
It's rather crude, but annoying winsock just doesn't set the errno properly. Compile source and your vlc-server will now properly *wait* for a password
recv docs on msdn:
recv() call