コード例 #1
0
ファイル: TCPServer.cpp プロジェクト: ZaaaV/domoticz
void CTCPServerInt::stopClient(CTCPClient_ptr c)
{
	boost::lock_guard<boost::mutex> l(connectionMutex);

	//std::string s = c->socket().remote_endpoint().address().to_string();
	//_log.Log(LOG_STATUS,"Closing connection from: %s", s.c_str());
	if (connections_.find(c)!=connections_.end())
	{
		connections_.erase(c);
		c->stop();
	}
}
コード例 #2
0
ファイル: TCPServer.cpp プロジェクト: clafa/domoticz
void CTCPServerInt::stopClient(CTCPClient_ptr c)
{
	boost::lock_guard<boost::mutex> l(connectionMutex);
	connections_.erase(c);
	c->stop();
}