Fix for issue #4

master
sta 14 years ago
parent 475d299c3d
commit 0f0a05feb2

Binary file not shown.

@ -112,7 +112,7 @@ namespace Example
Console.Write("> ");
data = Console.ReadLine();
if (data == "exit")
if (data == "exit" || !ws.IsConnected)
{
break;
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -1,5 +1,5 @@
<Properties>
<MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
<MonoDevelop.Ide.Workspace ActiveConfiguration="Release_Ubuntu" />
<MonoDevelop.Ide.Workbench />
<MonoDevelop.Ide.DebuggingService.Breakpoints>
<BreakpointStore />

@ -124,12 +124,14 @@ namespace WebSocketSharp
if (socket.Poll(0, SelectMode.SelectWrite) &&
!socket.Poll(0, SelectMode.SelectError))
{
var buffer = new byte[1];
// var buffer = new byte[1];
//
// if (socket.Receive(buffer, SocketFlags.Peek) != 0)
// {
// return true;
// }
if (socket.Receive(buffer, SocketFlags.Peek) != 0)
{
return true;
}
return true;
}
return false;

Loading…
Cancel
Save