diff --git a/include/libtorrent/http_stream.hpp b/include/libtorrent/http_stream.hpp index 3139ef29b..8f97d8aa6 100644 --- a/include/libtorrent/http_stream.hpp +++ b/include/libtorrent/http_stream.hpp @@ -68,11 +68,13 @@ public: proxy_base::close(ec); } +#ifndef BOOST_NO_EXCEPTIONS void close() { m_dst_name.clear(); proxy_base::close(); } +#endif typedef boost::function handler_type; diff --git a/include/libtorrent/socks5_stream.hpp b/include/libtorrent/socks5_stream.hpp index 9a668ad9a..0922199b5 100644 --- a/include/libtorrent/socks5_stream.hpp +++ b/include/libtorrent/socks5_stream.hpp @@ -110,12 +110,14 @@ public: proxy_base::close(ec); } +#ifndef BOOST_NO_EXCEPTIONS void close() { m_hostname.clear(); m_dst_name.clear(); proxy_base::close(); } +#endif typedef boost::function handler_type;