DELTA 300507 0 26 SVNoG5,T# $FreeBSD$ PORTNAME?= libtorrent PORTVERSION?= 0.13.2 PORTREVISION= 1gnomehack USE_PKGCONFIG= build USE_OPENSSL= yes USE_LDCONFIG= yes GNU_CONFIGURE= yes OPTIONS_DEFINE= KQUEUE IPV6 OPTIONS_DEFAULT= KQUEUE KQUEUE_DESC= Use kqueue(2) support${PORT_OPTIONS:MKQUEUE} CONFIGURE_ARGS+= --with-kqueue .endif .if ${PORT_OPTIONS:MIPV6} CONFIGURE_ARGS+= --enable-ipv6 .endif .include ENDREP DELTA SVNz|zz--- 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); } }ENDREP DELTA 130335 1644 548 SVN]M]]x^T]o0}ƿ"MZiөR%t $v[ѪZs=`oTq>dfgZW*7[Pfo1Jn=x˧6aF-%p 1;iʁetO^uBK<+w(M8r|l8m/biS]gC)mf/ `u0m] Y*oU4gcB.Veq6KsULz]E|?MI G26A:< RL<]Q̂0/8+yXW99