From a9b51e1579b4cf29c22669ffa397d07908e67f9f Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Tue, 18 Oct 2011 16:22:36 +0000 Subject: [PATCH] fix overflow issue when determining number of outstanding bytes --- src/peer_connection.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/peer_connection.cpp b/src/peer_connection.cpp index 4f2d52d69..b4006a3fe 100644 --- a/src/peer_connection.cpp +++ b/src/peer_connection.cpp @@ -4354,7 +4354,7 @@ namespace libtorrent // only add new piece-chunks if the send buffer is small enough // otherwise there will be no end to how large it will be! - int upload_rate = int(m_statistics.upload_rate()); + boost::uint64_t upload_rate = int(m_statistics.upload_rate()); int buffer_size_watermark = upload_rate * m_ses.settings().send_buffer_watermark_factor / 100;