diff --git a/src/transport.cpp b/src/transport.cpp index 3fc63aecfcfa0b5c9f769c4fb31ff631b0a43845..20f82807abf27066b8fd2ceec6510c5c9325f6c7 100644 --- a/src/transport.cpp +++ b/src/transport.cpp @@ -159,7 +159,7 @@ void Component::setBuddyFeatures(std::list &features) { } void Component::start() { - if (m_component) { + 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")); m_reconnectCount++; m_component->connect(CONFIG_STRING(m_config, "service.server"), CONFIG_INT(m_config, "service.port"));