namespace {
-bool closing_ = false;
-
-void closing()
-{
- closing_ = true;
-}
-
-
char * errormsg()
{
void * msgbuf;
LyXComm::LyXComm(string const & pip, Server * cli, ClientCallbackfct ccb)
: pipename_(pip), client_(cli), clientcb_(ccb), stopserver_(0)
{
- // Ask Qt to notify us on quit.
- qAddPostRoutine(closing);
ready_ = false;
openConnection();
}
BOOL LyXComm::checkStopServer()
{
- return WaitForSingleObject(stopserver_, 0) == WAIT_OBJECT_0 || closing_;
+ return WaitForSingleObject(stopserver_, 0) == WAIT_OBJECT_0;
}
}
if (!ready_) {
- LYXERR0("LyXComm: Already disconnected");
+ LYXERR(Debug::LYXSERVER, "LyXComm: Already disconnected");
return;
}