diff options
author | Remko Tronçon <git@el-tramo.be> | 2009-07-25 22:05:30 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2009-07-25 22:07:33 (GMT) |
commit | 2833b8f09c9aef09004662a2a89eefbaee1e4247 (patch) | |
tree | a63f528cffbe811707b581b87f3cef855bc69635 /Swiften/LinkLocal/LinkLocalServiceBrowser.cpp | |
parent | 2b749bb5665adf893188faec1c299e23dd9c6c9f (diff) | |
download | swift-2833b8f09c9aef09004662a2a89eefbaee1e4247.zip swift-2833b8f09c9aef09004662a2a89eefbaee1e4247.tar.bz2 |
Implement LinkLocalService.
Diffstat (limited to 'Swiften/LinkLocal/LinkLocalServiceBrowser.cpp')
-rw-r--r-- | Swiften/LinkLocal/LinkLocalServiceBrowser.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/Swiften/LinkLocal/LinkLocalServiceBrowser.cpp b/Swiften/LinkLocal/LinkLocalServiceBrowser.cpp index 6634a0a..4e9c2de 100644 --- a/Swiften/LinkLocal/LinkLocalServiceBrowser.cpp +++ b/Swiften/LinkLocal/LinkLocalServiceBrowser.cpp @@ -20,7 +20,6 @@ LinkLocalServiceBrowser::~LinkLocalServiceBrowser() { browseQuery->stopBrowsing(); } -/* std::vector<LinkLocalService> LinkLocalServiceBrowser::getServices() const { std::vector<LinkLocalService> result; for (ServiceMap::const_iterator i = services.begin(); i != services.end(); ++i) { @@ -28,7 +27,6 @@ std::vector<LinkLocalService> LinkLocalServiceBrowser::getServices() const { } return result; } -*/ void LinkLocalServiceBrowser::handleServiceAdded(const DNSSDServiceID& service) { boost::shared_ptr<DNSSDResolveServiceQuery> resolveQuery = querier->createResolveServiceQuery(service); @@ -50,11 +48,7 @@ void LinkLocalServiceBrowser::handleServiceRemoved(const DNSSDServiceID& service } void LinkLocalServiceBrowser::handleServiceResolved(const DNSSDServiceID& service, const boost::optional<DNSSDResolveServiceQuery::Result>& result) { - if (!result) { - // TODO - std::cerr << "Error resolving" << std::endl; - } - else { + if (result) { std::pair<ServiceMap::iterator, bool> r = services.insert(std::make_pair(service, *result)); if (r.second) { onServiceAdded(service); |