Changeset - 7779ba775e9b
[Not reviewed]
0 1 0
HanzZ - 14 years ago 2011-07-24 22:53:19
hanzz.k@gmail.com
reverted disconnecting
1 file changed with 5 insertions and 2 deletions:
0 comments (0 inline, 0 general)
src/networkpluginserver.cpp
Show inline comments
 
@@ -566,13 +566,14 @@ void NetworkPluginServer::pingTimeout() {
 
		if ((*it)->pongReceived || (*it)->pongReceived == -1) {
 
			sendPing((*it));
 
		}
 
		else {
 
			LOG4CXX_INFO(logger, "Disconnecting backend " << (*it) << ". PING response not received.");
 
			(*it)->connection->disconnect();
 
			handleSessionFinished((*it));
 
			(*it)->connection.reset();
 
// 			handleSessionFinished((*it));
 
		}
 
		
 
	}
 
	m_pingTimer->start();
 
}
 

	
 
@@ -712,13 +713,15 @@ void NetworkPluginServer::handleUserDestroyed(User *user) {
 
	}
 
	send(c->connection, message);
 
	c->users.remove(user);
 
	if (c->users.size() == 0) {
 
		LOG4CXX_INFO(logger, "Disconnecting backend " << c << ". There are no users.");
 
		c->connection->disconnect();
 
		handleSessionFinished(c);
 
		c->connection.reset();
 
		
 
// 		handleSessionFinished(c);
 
// 		m_clients.erase(user->connection);
 
	}
 
}
 

	
 
void NetworkPluginServer::handleMessageReceived(NetworkConversation *conv, boost::shared_ptr<Swift::Message> &msg) {
 

	
0 comments (0 inline, 0 general)