diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-12-13 20:27:50 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-12-13 20:58:23 (GMT) |
commit | 27878a6a612af77fdc6f27dacc0201a8da92a1fb (patch) | |
tree | 20f1590258f2e6694e89b140a7ed603da33a1b16 /Swiften/Network/PlatformDomainNameServiceQuery.cpp | |
parent | 0863ece69f6490602e90b22c0dd17189bd8bf5a7 (diff) | |
download | swift-contrib-27878a6a612af77fdc6f27dacc0201a8da92a1fb.zip swift-contrib-27878a6a612af77fdc6f27dacc0201a8da92a1fb.tar.bz2 |
Added debug output to connector.
Diffstat (limited to 'Swiften/Network/PlatformDomainNameServiceQuery.cpp')
-rw-r--r-- | Swiften/Network/PlatformDomainNameServiceQuery.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Swiften/Network/PlatformDomainNameServiceQuery.cpp b/Swiften/Network/PlatformDomainNameServiceQuery.cpp index ed73b64..7ab6e7a 100644 --- a/Swiften/Network/PlatformDomainNameServiceQuery.cpp +++ b/Swiften/Network/PlatformDomainNameServiceQuery.cpp @@ -27,6 +27,7 @@ #include "Swiften/Base/ByteArray.h" #include "Swiften/EventLoop/EventLoop.h" #include "Swiften/Base/foreach.h" +#include <Swiften/Base/Log.h> using namespace Swift; @@ -51,6 +52,8 @@ void PlatformDomainNameServiceQuery::run() { } void PlatformDomainNameServiceQuery::doRun() { + SWIFT_LOG(debug) << "Querying " << service << std::endl; + std::vector<DomainNameServiceQuery::Result> records; #if defined(SWIFTEN_PLATFORM_WINDOWS) @@ -84,11 +87,11 @@ void PlatformDomainNameServiceQuery::doRun() { // Make sure we reinitialize the domain list every time res_init(); - //std::cout << "SRV: Querying " << service << std::endl; ByteArray response; response.resize(NS_PACKETSZ); int responseLength = res_query(const_cast<char*>(service.getUTF8Data()), ns_c_in, ns_t_srv, reinterpret_cast<u_char*>(response.getData()), response.getSize()); if (responseLength == -1) { + SWIFT_LOG(debug) << "Error" << std::endl; emitError(); return; } |