diff options
author | Florent Le Coz <louiz@louiz.org> | 2015-10-26 19:44:31 +0100 |
---|---|---|
committer | Florent Le Coz <louiz@louiz.org> | 2015-10-26 20:01:57 +0100 |
commit | 0fcba76c793e7c0b1ccc09eaa85016caa11ca3f2 (patch) | |
tree | b1979d96cda94c64b768789419e54ce063e09405 | |
parent | e43ca29e94342ab8e3cd8be54d6935bb450c00fe (diff) | |
download | biboumi-0fcba76c793e7c0b1ccc09eaa85016caa11ca3f2.tar.gz biboumi-0fcba76c793e7c0b1ccc09eaa85016caa11ca3f2.tar.bz2 biboumi-0fcba76c793e7c0b1ccc09eaa85016caa11ca3f2.tar.xz biboumi-0fcba76c793e7c0b1ccc09eaa85016caa11ca3f2.zip |
Fix a build issue when compiling without cares
-rw-r--r-- | louloulibs/network/resolver.cpp | 2 | ||||
-rw-r--r-- | louloulibs/network/resolver.hpp | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/louloulibs/network/resolver.cpp b/louloulibs/network/resolver.cpp index 0150fc8..cb6c445 100644 --- a/louloulibs/network/resolver.cpp +++ b/louloulibs/network/resolver.cpp @@ -23,7 +23,9 @@ void Resolver::resolve(const std::string& hostname, const std::string& port, { this->error_cb = error_cb; this->success_cb = success_cb; +#ifdef CARES_FOUND this->port = port; +#endif this->start_resolving(hostname, port); } diff --git a/louloulibs/network/resolver.hpp b/louloulibs/network/resolver.hpp index 511afd2..f9e9134 100644 --- a/louloulibs/network/resolver.hpp +++ b/louloulibs/network/resolver.hpp @@ -66,12 +66,12 @@ public: #ifdef CARES_FOUND this->resolved6 = false; this->resolved4 = false; -#endif - this->resolved = false; this->resolving = false; - this->addr.reset(); this->cares_addrinfo = nullptr; this->port.clear(); +#endif + this->resolved = false; + this->addr.reset(); this->error_msg.clear(); } |