Sockets implementation for Windows, WebSockets client now working.

This commit is contained in:
Ben Vanik
2013-12-16 22:43:03 -08:00
parent d548e7f770
commit b5f5668f6d
8 changed files with 216 additions and 19 deletions

View File

@@ -17,7 +17,7 @@ using namespace xe::debug;
using namespace xe::debug::protocols::gdb;
#if 0
GDBClient::GDBClient(DebugServer* debug_server, int socket_id) :
GDBClient::GDBClient(DebugServer* debug_server, socket_t socket_id) :
DebugClient(debug_server),
thread_(NULL),
socket_id_(socket_id) {

View File

@@ -26,7 +26,7 @@ namespace gdb {
class GDBClient : public DebugClient {
public:
GDBClient(DebugServer* debug_server, int socket_id);
GDBClient(DebugServer* debug_server, socket_t socket_id);
virtual ~GDBClient();
socket_t socket_id();

View File

@@ -25,7 +25,7 @@ using namespace xe::debug;
using namespace xe::debug::protocols::ws;
WSClient::WSClient(DebugServer* debug_server, int socket_id) :
WSClient::WSClient(DebugServer* debug_server, socket_t socket_id) :
DebugClient(debug_server),
thread_(NULL),
socket_id_(socket_id) {
@@ -52,10 +52,6 @@ WSClient::~WSClient() {
xe_thread_release(thread_);
}
int WSClient::socket_id() {
return socket_id_;
}
int WSClient::Setup() {
// Prep the socket.
xe_socket_set_keepalive(socket_id_, true);

View File

@@ -29,10 +29,10 @@ namespace ws {
class WSClient : public DebugClient {
public:
WSClient(DebugServer* debug_server, int socket_id);
WSClient(DebugServer* debug_server, socket_t socket_id);
virtual ~WSClient();
socket_t socket_id();
socket_t socket_id() const { return socket_id_; }
virtual int Setup();