|
|
|
@ -183,7 +183,7 @@ Dispatcher::Dispatcher(IOManager *ioManager, StartServer startServer)
|
|
|
|
|
if(!unixServer->running())
|
|
|
|
|
{
|
|
|
|
|
delete unixServer;
|
|
|
|
|
arts_warning("MCOP: couldn't start UnixServer");
|
|
|
|
|
arts_warning("[mcop dispatcher] Couldn't start UnixServer");
|
|
|
|
|
unixServer = 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -195,7 +195,7 @@ Dispatcher::Dispatcher(IOManager *ioManager, StartServer startServer)
|
|
|
|
|
if(!tcpServer->running())
|
|
|
|
|
{
|
|
|
|
|
delete tcpServer;
|
|
|
|
|
arts_warning("MCOP: couldn't start TCPServer");
|
|
|
|
|
arts_warning("[mcop dispatcher] Couldn't start TCPServer");
|
|
|
|
|
tcpServer = 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -216,7 +216,7 @@ Dispatcher::Dispatcher(IOManager *ioManager, StartServer startServer)
|
|
|
|
|
orig_sigpipe = signal(SIGPIPE,SIG_IGN);
|
|
|
|
|
if((orig_sigpipe != SIG_DFL) && (orig_sigpipe != SIG_IGN))
|
|
|
|
|
{
|
|
|
|
|
cerr << "mcop warning: user defined signal handler found for"
|
|
|
|
|
cerr << "[mcop dispatcher] warning: user defined signal handler found for"
|
|
|
|
|
" SIG_PIPE, overriding" << endl;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -283,7 +283,7 @@ Dispatcher::Dispatcher(IOManager *ioManager, StartServer startServer)
|
|
|
|
|
* happen. In this case, we will remove the cookie and overwrite it
|
|
|
|
|
* with our previously generated cookie.
|
|
|
|
|
*/
|
|
|
|
|
arts_warning("bad md5 secret-cookie obtained from %s - replacing it",
|
|
|
|
|
arts_warning("[mcop dispatcher] Bad md5 secret-cookie obtained from %s - replacing it",
|
|
|
|
|
globalComm()._interfaceName().c_str());
|
|
|
|
|
|
|
|
|
|
globalComm().erase("secret-cookie");
|
|
|
|
@ -390,7 +390,7 @@ Dispatcher::~Dispatcher()
|
|
|
|
|
|
|
|
|
|
if(Object_base::_objectCount())
|
|
|
|
|
{
|
|
|
|
|
cerr << "warning: leaving MCOP Dispatcher and still "
|
|
|
|
|
cerr << "[mcop dispatcher] warning: leaving MCOP Dispatcher and still "
|
|
|
|
|
<< Object_base::_objectCount() << " object references alive." << endl;
|
|
|
|
|
list<Object_skel *> which = objectPool.enumerate();
|
|
|
|
|
list<Object_skel *>::iterator i;
|
|
|
|
@ -400,13 +400,13 @@ Dispatcher::~Dispatcher()
|
|
|
|
|
|
|
|
|
|
if(Type::_typeCount())
|
|
|
|
|
{
|
|
|
|
|
cerr << "warning: leaving MCOP Dispatcher and still "
|
|
|
|
|
cerr << "[mcop dispatcher] warning: leaving MCOP Dispatcher and still "
|
|
|
|
|
<< Type::_typeCount() << " types alive." << endl;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if(GenericDataPacket::_dataPacketCount())
|
|
|
|
|
{
|
|
|
|
|
cerr << "warning: leaving MCOP Dispatcher and still "
|
|
|
|
|
cerr << "[mcop dispatcher] warning: leaving MCOP Dispatcher and still "
|
|
|
|
|
<< GenericDataPacket::_dataPacketCount()
|
|
|
|
|
<< " data packets alive." << endl;
|
|
|
|
|
}
|
|
|
|
@ -692,7 +692,7 @@ void Dispatcher::handle(Connection *conn, Buffer *buffer, long messageType)
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
cerr << "MCOP error: don't know authentication protocol" << endl;
|
|
|
|
|
cerr << "[mcop dispatcher] error: don't know authentication protocol" << endl;
|
|
|
|
|
cerr << " server offered: ";
|
|
|
|
|
for(ai = h.authProtocols.begin(); ai != h.authProtocols.end(); ai++)
|
|
|
|
|
cerr << *ai << " ";
|
|
|
|
@ -775,11 +775,11 @@ void Dispatcher::handle(Connection *conn, Buffer *buffer, long messageType)
|
|
|
|
|
/*
|
|
|
|
|
* We shouldn't reach this point if everything went all right
|
|
|
|
|
*/
|
|
|
|
|
cerr << "Fatal communication error with a client" << endl;
|
|
|
|
|
cerr << "[mcop dispatcher] Fatal communication error with a client" << endl;
|
|
|
|
|
if(conn->connState() != Connection::established)
|
|
|
|
|
{
|
|
|
|
|
cerr << " Authentication of this client was not successful" << endl;
|
|
|
|
|
cerr << " Connection dropped" << endl;
|
|
|
|
|
cerr << "[mcop dispatcher] Authentication of this client was not successful" << endl;
|
|
|
|
|
cerr << "[mcop dispatcher] Connection dropped" << endl;
|
|
|
|
|
conn->drop();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -996,14 +996,14 @@ void Dispatcher::handleCorrupt(Connection *connection)
|
|
|
|
|
{
|
|
|
|
|
if(connection->connState() != Connection::established)
|
|
|
|
|
{
|
|
|
|
|
cerr << "received corrupt message on unauthenticated connection" <<endl;
|
|
|
|
|
cerr << "[mcop dispatcher] Received corrupt message on unauthenticated connection" <<endl;
|
|
|
|
|
cerr << "closing connection." << endl;
|
|
|
|
|
connection->drop();
|
|
|
|
|
d->serverConnectCondition.wakeAll();
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
cerr << "WARNING: got corrupt MCOP message !??" << endl;
|
|
|
|
|
cerr << "[mcop dispatcher] warning: got corrupt MCOP message !??" << endl;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|