forked from glynos/cpp-netlib
-
Notifications
You must be signed in to change notification settings - Fork 426
Closed
Description
I have a program that uses cpp-netlib in a very simple way to download some files, and sometimes it hangs indefinitely during a download operation.
I have attached the debugger during the hang, and the stack trace is as follows:
#0 0x00007f68b1ade85c in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
#1 0x00000000004307bf in boost::condition_variable::wait(boost::unique_lock<boost::mutex>&) ()
#2 0x000000000043204e in boost::detail::shared_state_base::wait_internal(boost::unique_lock<boost::mutex>&, bool) ()
#3 0x000000000043210c in boost::detail::shared_state_base::wait(bool) ()
#4 0x00000000004b1010 in boost::detail::shared_state<std::string>::get_sh() ()
#5 0x0000000000495a28 in boost::shared_future<std::string>::get() ()
#6 0x00000000004777cc in boost::network::http::async_message<boost::network::http::tags::http_async_8bit_udp_resolve>::body() const ()
#7 0x000000000045a3b1 in boost::network::http::impl::body_wrapper<boost::network::http::basic_response<boost::network::http::tags::http_async_8bit_udp_resolve> >::operator std::string() const ()
#8 0x000000000043726d in download_file(std::string const&) ()
download_file is a very simple function that looks like this:
std::string download_file(const std::string& url)
{
using namespace boost::network;
using namespace boost::network::http;
return body(client().get(client::request(url)));
}
Any ideas as to what is going wrong, or how I can diagnose the issue further?
Metadata
Metadata
Assignees
Labels
No labels