X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FServer.cpp;h=1de758a5f46bd1b9507c9e2ad9b213d9a015c550;hb=9130bdb5ecaa7cc9a7c50f0bd3ee75332a5ba145;hp=1e673e6f8708e9fa1701b74dc0572dcc0d271c42;hpb=ea3154184833f4f2426eb2a956878e83ddd822d9;p=lyx.git diff --git a/src/Server.cpp b/src/Server.cpp index 1e673e6f87..1de758a5f4 100644 --- a/src/Server.cpp +++ b/src/Server.cpp @@ -695,6 +695,7 @@ string const LyXComm::pipeName(DWORD index) const LyXComm::LyXComm(string const &, Server *, ClientCallbackfct) {} + void LyXComm::openConnection() {} @@ -716,6 +717,7 @@ void LyXComm::endPipe(int & fd, string const & filename, bool write) void LyXComm::emergencyCleanup() {} + void LyXComm::read_ready() {} @@ -726,7 +728,6 @@ void LyXComm::send(string const & msg) #else // defined (HAVE_MKFIFO) - LyXComm::LyXComm(string const & pip, Server * cli, ClientCallbackfct ccb) : pipename_(pip), client_(cli), clientcb_(ccb) { @@ -915,7 +916,6 @@ void LyXComm::read_ready() int status; // the single = is intended here. while ((status = ::read(infd_, charbuf, charbuf_size - 1))) { - if (status > 0) { charbuf[status] = '\0'; // turn it into a c string read_buffer_ += rtrim(charbuf, "\r"); @@ -966,7 +966,8 @@ void LyXComm::send(string const & msg) LYXERR(Debug::LYXSERVER, "LyXComm: Sending '" << msg << '\''); - if (pipename_.empty()) return; + if (pipename_.empty()) + return; if (!ready_) { LYXERR0("LyXComm: Pipes are closed. Could not send " << msg); @@ -1068,7 +1069,6 @@ Server::~Server() int compare(char const * a, char const * b, unsigned int len) { - using namespace std; return strncmp(a, b, len); }