diff options
Diffstat (limited to 'Swiften/Network/Connector.cpp')
-rw-r--r-- | Swiften/Network/Connector.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Swiften/Network/Connector.cpp b/Swiften/Network/Connector.cpp index a58efbc..da2490f 100644 --- a/Swiften/Network/Connector.cpp +++ b/Swiften/Network/Connector.cpp @@ -32,11 +32,11 @@ void Connector::start() { assert(!timer); queriedAllServices = false; - if (serviceLookupPrefix) { - serviceQuery = resolver->createServiceQuery((*serviceLookupPrefix) + hostname); - serviceQuery->onResult.connect(boost::bind(&Connector::handleServiceQueryResult, shared_from_this(), _1)); if (timeoutMilliseconds > 0) { timer = timerFactory->createTimer(timeoutMilliseconds); timer->onTick.connect(boost::bind(&Connector::handleTimeout, shared_from_this())); } + if (serviceLookupPrefix) { + serviceQuery = resolver->createServiceQuery((*serviceLookupPrefix) + hostname); + serviceQuery->onResult.connect(boost::bind(&Connector::handleServiceQueryResult, shared_from_this(), _1)); serviceQuery->run(); } |