X-Git-Url: https://git.llucax.com/z.facultad/75.42/plaqui.git/blobdiff_plain/f27c218d18ebf7198e07249aca1eed625da914fd..b0a202776ab7634c206b495b42e20cfe6492e035:/Server/src/controlserver.cpp?ds=inline diff --git a/Server/src/controlserver.cpp b/Server/src/controlserver.cpp index f5c6c73..32d3306 100644 --- a/Server/src/controlserver.cpp +++ b/Server/src/controlserver.cpp @@ -63,7 +63,7 @@ void ControlServer::real_run(void) { while (!stop) { Command command; try { - Glib::Mutex::Lock lock(socket_mutex); + //Glib::Mutex::Lock lock(socket_mutex); socket >> command; // Si se cerrĂ³ el socket. } catch (const ios::failure& e) { @@ -77,6 +77,7 @@ void ControlServer::real_run(void) { << e.code << " | reason = " << HTTPMessage::reason(e.code) << " | desc = " << e.what() << endl; #endif // DEBUG + //Glib::Mutex::Lock lock(socket_mutex); socket << HTTPResponse(e) << flush; continue; } @@ -178,8 +179,11 @@ Accept-Ranges: bytes } void ControlServer::send(const HTTPResponse& response) { - Glib::Mutex::Lock lock(socket_mutex); + //Glib::Mutex::Lock lock(socket_mutex); socket << response << flush; +#ifdef DEBUG + cerr << __FILE__ << ": send() Enviado!" << endl; +#endif // DEBUG } ControlServer::SignalCommandReceived& ControlServer::signal_command_received(void) {