Commit bcca70d7 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Telnet: fix win32 work.

Code by fpostma on the forum - fpostma __ xs4all | nl
Thanks to Lorni for testing.
Close #2022
parent eef31bda
...@@ -30,6 +30,10 @@ ...@@ -30,6 +30,10 @@
# include "config.h" # include "config.h"
#endif #endif
#ifdef WIN32
# include "winsock2.h"
#endif
#include <vlc_common.h> #include <vlc_common.h>
#include <vlc_plugin.h> #include <vlc_plugin.h>
#include <vlc_interface.h> #include <vlc_interface.h>
...@@ -371,6 +375,13 @@ static void Run( intf_thread_t *p_intf ) ...@@ -371,6 +375,13 @@ static void Run( intf_thread_t *p_intf )
cl->i_mode + 2 ); cl->i_mode + 2 );
} }
#ifdef WIN32
if( i_recv <= 0 && WSAGetLastError() == WSAEWOULDBLOCK )
{
errno=EAGAIN;
}
#endif
if (i_recv <= 0 && ( end || errno != EAGAIN ) ) if (i_recv <= 0 && ( end || errno != EAGAIN ) )
goto drop; goto drop;
} }
......
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