diff options
author | az <az@FreeBSD.org> | 2012-10-15 20:41:26 +0800 |
---|---|---|
committer | az <az@FreeBSD.org> | 2012-10-15 20:41:26 +0800 |
commit | fa038b1d88b0651326ae6e2b6f6732900a9c012c (patch) | |
tree | 0f87636f71fe137ce5a5a1f85a92409b23c9337f /net-p2p | |
parent | a7f50cf49d094f9c334e06d0085e27a4f1828f78 (diff) | |
download | freebsd-ports-graphics-fa038b1d88b0651326ae6e2b6f6732900a9c012c.tar.gz freebsd-ports-graphics-fa038b1d88b0651326ae6e2b6f6732900a9c012c.tar.zst freebsd-ports-graphics-fa038b1d88b0651326ae6e2b6f6732900a9c012c.zip |
- fix bug causing CPU load on FreeBSD.
- bump portrevisions.
PR: ports/170766
Submitted by: Yamagi Burmeister <yamagi@yamagi.org>
Approved by: maintainer (timeout > 2 weeks)
Feature safe: yes
Diffstat (limited to 'net-p2p')
-rw-r--r-- | net-p2p/libtorrent/Makefile | 1 | ||||
-rw-r--r-- | net-p2p/libtorrent/files/patch-src_torrent_utils_thread__base.cc | 20 | ||||
-rw-r--r-- | net-p2p/rtorrent/Makefile | 6 |
3 files changed, 24 insertions, 3 deletions
diff --git a/net-p2p/libtorrent/Makefile b/net-p2p/libtorrent/Makefile index 7d5eb2a4eca..1f23ffc54a4 100644 --- a/net-p2p/libtorrent/Makefile +++ b/net-p2p/libtorrent/Makefile @@ -2,6 +2,7 @@ PORTNAME?= libtorrent PORTVERSION?= 0.13.2 +PORTREVISION= 1 CATEGORIES= net-p2p MASTER_SITES= http://libtorrent.rakshasa.no/downloads/ \ ${MASTER_SITE_LOCAL} diff --git a/net-p2p/libtorrent/files/patch-src_torrent_utils_thread__base.cc b/net-p2p/libtorrent/files/patch-src_torrent_utils_thread__base.cc new file mode 100644 index 00000000000..8d17aaab9eb --- /dev/null +++ b/net-p2p/libtorrent/files/patch-src_torrent_utils_thread__base.cc @@ -0,0 +1,20 @@ +--- src/torrent/utils/thread_base.cc.orig ++++ src/torrent/utils/thread_base.cc +@@ -88,6 +88,8 @@ thread_base::stop_thread_wait() { + + void + thread_base::interrupt() { ++ int sleep_length = 0; ++ + __sync_fetch_and_or(&m_flags, flag_no_timeout); + + while (is_polling() && has_no_timeout()) { +@@ -96,7 +98,8 @@ thread_base::interrupt() { + if (!(is_polling() && has_no_timeout())) + return; + +- usleep(0); ++ usleep(sleep_length); ++ sleep_length = std::min(sleep_length + 50, 1000); + } + }
\ No newline at end of file diff --git a/net-p2p/rtorrent/Makefile b/net-p2p/rtorrent/Makefile index 5cb7e43ae75..995e571079d 100644 --- a/net-p2p/rtorrent/Makefile +++ b/net-p2p/rtorrent/Makefile @@ -2,7 +2,7 @@ PORTNAME?= rtorrent PORTVERSION?= 0.9.2 -PORTREVISION?= 0 +PORTREVISION?= 1 CATEGORIES= net-p2p MASTER_SITES= http://libtorrent.rakshasa.no/downloads/ \ ${MASTER_SITE_LOCAL} @@ -11,8 +11,8 @@ MASTER_SITE_SUBDIR= flz/rtorrent/ MAINTAINER?= flz@FreeBSD.org COMMENT?= BitTorrent Client written in C++ -BUILD_DEPENDS?= libtorrent=0.13.2:${PORTSDIR}/net-p2p/libtorrent -RUN_DEPENDS?= libtorrent=0.13.2:${PORTSDIR}/net-p2p/libtorrent +BUILD_DEPENDS?= libtorrent=0.13.2_1:${PORTSDIR}/net-p2p/libtorrent +RUN_DEPENDS?= libtorrent=0.13.2_1:${PORTSDIR}/net-p2p/libtorrent LIB_DEPENDS?= curl.6:${PORTSDIR}/ftp/curl CONFLICTS?= rtorrent-devel-[0-9]* |