Changeset - 6b71ab5bf093
[Not reviewed]
0 1 0
Jan Kaluza - 13 years ago 2012-07-17 13:27:00
hanzz.k@gmail.com
Show warning when connecting the server on port 5222
1 file changed with 3 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/transport.cpp
Show inline comments
 
@@ -188,12 +188,15 @@ void Component::setBuddyFeatures(std::list<std::string> &features) {
 
	m_discoInfoResponder->setBuddyFeatures(features);
 
}
 

	
 
void Component::start() {
 
	if (m_component && !m_component->isAvailable()) {
 
		LOG4CXX_INFO(logger, "Connecting XMPP server " << CONFIG_STRING(m_config, "service.server") << " port " << CONFIG_INT(m_config, "service.port"));
 
		if (CONFIG_INT(m_config, "service.port") == 5222) {
 
			LOG4CXX_WARN(logger, "Port 5222 is usually used for client connections, not for component connections! Are you sure you are using right port?");
 
		}
 
		m_reconnectCount++;
 
		m_component->connect(CONFIG_STRING(m_config, "service.server"), CONFIG_INT(m_config, "service.port"));
 
		m_reconnectTimer->stop();
 
	}
 
	else if (m_server) {
 
		LOG4CXX_INFO(logger, "Starting component in server mode on port " << CONFIG_INT(m_config, "service.port"));
0 comments (0 inline, 0 general)