I started having problems connecting to some RTSP streams and traced it to line
400 in the RTSPClient
00399 if (connect(socketNum, (struct sockaddr*) &remoteName, sizeof remoteName)
!= 0) {
00400 if (envir().getErrno() == EINPROGRESS) {
00401 // The connection is pending; we'll need to handle it later. Wait
for our socket to be 'writable', or have an exception.
00402 envir().taskScheduler().setBackgroundHandling(socketNum,
SOCKET_WRITABLE|SOCKET_EXCEPTION,
00403
(TaskScheduler::BackgroundHandlerProc*)&connectionHandler, this);
00404 return 0;
00405 }
00406 envir().setResultErrMsg("connect() failed: ");
00407 if (fVerbosityLevel >= 1) envir() << "..." << envir().getResultMsg()
<< "\n";
00408 return -1;
00409 }
My windows API started returning WSAEWOULDBLOCK which according to MSDN is fine
to be rescheduled for later
WSAEWOULDBLOCK = 10035
Resource temporarily unavailable.
This error is returned from operations on nonblocking sockets that cannot
be completed immediately, for example recv when no data is queued to be read
from the socket. It is a nonfatal error, and the operation should be retried
later. It is normal for WSAEWOULDBLOCK to be reported as the result from
calling connect on a nonblocking SOCK_STREAM socket, since some time must
elapse for the connection to be established.
Should I change the if clause on line 400? Or did I somehow mess up the sockets
on my computer.
I have rebooted, there was a windows update this am. I am on Win7 64bit but
running a win32 app.
I noticed the setupStreams enables non-blocking sockets by default
_______________________________________________
live-devel mailing list
[email protected]
http://lists.live555.com/mailman/listinfo/live-devel