Commit Graph

4864 Commits

Author SHA1 Message Date
Arvid Norberg ec472daee3 fix bug in peer_connection causing it to not connect when not having metadata 2014-10-12 06:29:34 +00:00
Arvid Norberg a91848962a merge changes from RC_1_0 2014-10-12 04:18:34 +00:00
Arvid Norberg ab34239447 fix invalid comment 2014-10-10 00:16:17 +00:00
Arvid Norberg a113988e81 do a slightly better job of deciding which peers to save in resume data 2014-10-07 08:29:20 +00:00
Arvid Norberg b55778a847 some DHT logging and parsing 2014-10-07 07:23:20 +00:00
Arvid Norberg 04760d8f0f http_connection cleanup 2014-10-06 08:39:05 +00:00
Arvid Norberg 0cd2e74f28 remove invalid assert 2014-10-06 05:02:00 +00:00
Arvid Norberg f1032586f7 http_connection fix 2014-10-06 03:19:29 +00:00
Arvid Norberg 9b8e7bc169 fix typo in ssl patch 2014-10-06 03:18:26 +00:00
Arvid Norberg a655047cb0 support SSL over uTP (unit test is still failing with same errors as previously, this has not been fixed yet) 2014-10-06 03:03:01 +00:00
Arvid Norberg 8168c8520a minor tweak to inactivity timer fix 2014-10-05 22:31:29 +00:00
Arvid Norberg 30d7b9e3c3 fixed bug with inactivity timer 2014-10-05 22:30:09 +00:00
Arvid Norberg 418e33facc use the session-wide hostname resolver in torrent.cpp 2014-10-05 01:23:22 +00:00
Arvid Norberg 3c7a932aee update comments 2014-10-04 20:06:46 +00:00
Arvid Norberg d296960efa fix build with verbose logging 2014-10-04 19:54:12 +00:00
Arvid Norberg 520aead4da fix auto_sequential logic 2014-10-04 07:41:41 +00:00
Arvid Norberg 8af9e22938 remove invalid assert 2014-10-04 07:38:10 +00:00
Arvid Norberg ceccc2a483 land branch to remove half-open connection limit / connection queue 2014-10-03 20:56:57 +00:00
Arvid Norberg 65473fa783 fix geoip left-overs in src/Makefile.am 2014-10-03 20:56:10 +00:00
Arvid Norberg 7830081585 merged changes from RC_1_0 2014-10-01 18:19:44 +00:00
Arvid Norberg 0ed0bdc50c remove pointless DHT extension (for IPv6) 2014-10-01 16:21:29 +00:00
Arvid Norberg ba3ffe52f8 improve DHT logging a bit 2014-10-01 09:14:49 +00:00
Arvid Norberg f8272b90ae merged changes from RC_1_0 2014-09-29 07:06:18 +00:00
Arvid Norberg 2d438e0758 factor out parse_tracker_response and add unit tests. make gen_todo cover tests also, and regenerate todo.html 2014-09-29 06:10:22 +00:00
Arvid Norberg 1c915f2e95 merge changes from RC_1_0 2014-09-28 20:02:43 +00:00
Arvid Norberg 8664ff97aa optimize tracker_manager interface to avoid rendering and parsing strings for each peer-ip 2014-09-28 06:36:03 +00:00
Arvid Norberg 931c5530c2 some socks5 cleanup 2014-09-28 05:42:35 +00:00
Arvid Norberg 19d0087911 one last fix to the web_seed_entry patch 2014-09-28 05:41:50 +00:00
Arvid Norberg 6a4a5419c2 one more fix 2014-09-28 04:05:44 +00:00
Arvid Norberg d723a7a4c6 fix build 2014-09-28 03:27:13 +00:00
Arvid Norberg 154cbeb5cf support web seeds that resolve to multiple IPs 2014-09-28 02:20:13 +00:00
Arvid Norberg 9a985d197f optimize num_seeds() and num_downloaders() to not count the peers every time 2014-09-24 09:03:57 +00:00
Arvid Norberg 60119bf0ca added auto-sequential feature 2014-09-24 00:02:00 +00:00
Arvid Norberg 8cbef3876a post alert on outgoing get_peers 2014-09-22 19:49:32 +00:00
Arvid Norberg 7a55069ec9 add additional single-thread asserts and separate torrents from the session (in preparation for running them in separate threads/strands) 2014-09-22 17:41:06 +00:00
Arvid Norberg a6eda97281 fix optimistic unchoke stats gauge 2014-09-22 07:34:10 +00:00
Arvid Norberg d7d498c3a3 more steps towards isolating peer_connections from the session object. unchoking now happens via the torrent object. hopefully in the future, the session can determine which peers to unchoke without having direct access to them (i.e. with a mutex) 2014-09-22 03:47:43 +00:00
Arvid Norberg 27b7705cf2 remove built-in GeoIP support 2014-09-21 21:01:48 +00:00
Arvid Norberg 2936556573 fix bug in delay-load feature of torrents 2014-09-21 02:06:03 +00:00
Arvid Norberg c7a0bde196 fix bug in peer_connection::second_tick 2014-09-20 23:57:59 +00:00
Arvid Norberg 645d3cdb32 merge fixes from RC_1_0 2014-09-20 19:27:29 +00:00
Arvid Norberg c471bcb49f optimize peer classes a bit 2014-09-17 07:23:41 +00:00
Arvid Norberg 7e69239991 merged unit test from RC_1_0 2014-09-17 02:10:48 +00:00
Arvid Norberg 9a2e511dda attempted fix for inconsistent debug refcounters on blocks. pinning pieces with outstanding reads in an attempt at fixing inconsitencies seen around that logic as well 2014-09-14 22:42:18 +00:00
Arvid Norberg ad7d74f255 merged fixes from RC_1_0 2014-09-13 19:47:51 +00:00
Arvid Norberg 252e08a889 merged fixes from RC_1_0 2014-09-04 08:55:24 +00:00
Arvid Norberg bed6d5c233 fix test builds without deprecated functions 2014-09-03 03:17:47 +00:00
Arvid Norberg 649d7646fb test build fix. another boost.chrono overflow issue fixed 2014-09-02 08:01:09 +00:00
Arvid Norberg b74f5b13ef fix another boost.chrono time overflow issue 2014-09-02 07:31:41 +00:00
Arvid Norberg 4d57456199 merged changes from RC_1_0 2014-09-02 06:28:27 +00:00
Arvid Norberg 57b00ae42e fix bug in hostname resolver 2014-09-01 07:26:29 +00:00
Arvid Norberg ddb133e055 merged changes from RC_1_0 2014-08-31 21:17:32 +00:00
Arvid Norberg 2f3e3caf0f fixed typo 2014-08-31 08:34:03 +00:00
Arvid Norberg 44021c99e1 add todo comment 2014-08-28 08:06:11 +00:00
Arvid Norberg 48e4cf9478 merged changes from RC_1_0 2014-08-28 07:11:34 +00:00
Arvid Norberg 97a8e3b895 fix build error with verbose logging 2014-08-28 07:02:43 +00:00
Arvid Norberg 98c4c9327b merged change from RC_1_0 2014-08-28 02:06:21 +00:00
Arvid Norberg 83c0a4e519 build fixes 2014-08-27 07:50:36 +00:00
Arvid Norberg db788c9180 fix to make active_time, seeding_time, finished_time and upload_only_time all work for torrents that are not being ticked 2014-08-27 06:36:28 +00:00
Arvid Norberg 48ea42c990 merged changes from RC_1_0 2014-08-27 05:57:37 +00:00
Arvid Norberg 1ce69d122b add missing files 2014-08-27 03:33:41 +00:00
Arvid Norberg 45d8e36da4 merged Steve Siloti's refactoring patch of inter-thread calls into session_impl 2014-08-26 04:51:09 +00:00
Arvid Norberg 4ddedc6a21 add extension hook on sending payload 2014-08-26 04:26:16 +00:00
Arvid Norberg 7d751b80da merged fixes from RC_1_0 2014-08-26 03:14:32 +00:00
Arvid Norberg d2c64915bf simplified want_peers expression 2014-08-22 08:55:37 +00:00
Arvid Norberg 862844e546 merged changes from RC_1_0 2014-08-22 07:56:10 +00:00
Arvid Norberg 07af6f6216 merged changes from RC_1_0 2014-08-20 07:02:03 +00:00
Arvid Norberg 9f8916a7a0 merged changes from RC_1_0 2014-08-18 23:05:10 +00:00
Arvid Norberg 51f2aafb43 clean up some time_t and srand() uses 2014-08-16 20:55:44 +00:00
Arvid Norberg 524384045c transition to use boost.random instead of rand() and custom pseudo random generator 2014-08-16 20:26:00 +00:00
Arvid Norberg 3f88389f05 merged changes from RC_1_0 2014-08-16 07:46:06 +00:00
Arvid Norberg 40559fa564 fix typo in peer_connection 2014-08-11 15:53:53 +00:00
Arvid Norberg 5e54d13dec merge fixes from RC_0_16 2014-08-07 05:00:29 +00:00
Arvid Norberg 0bc2d1eb8a cover edge case of receiving the response to a request before the callback of sending the request. fixes assert 2014-08-02 06:09:07 +00:00
Arvid Norberg c60ceacb71 switch over to use boost.atomic instead of home-built one 2014-08-01 07:32:54 +00:00
Arvid Norberg f32f5e96aa deprecate parts of cache_status and move those counters to session_stats counters. make the performance counters thread safe. fix some issues recently introduced to performance counters and the usage of them in client_test 2014-08-01 06:07:48 +00:00
Arvid Norberg 671ae32ae5 fix docs generation for stats counters 2014-07-30 02:00:14 +00:00
Arvid Norberg f0be98ce53 cleanup and make session_stats a bit more efficient 2014-07-30 00:34:53 +00:00
Arvid Norberg 02f3e48eaa make performance counters able to blend in values, reducing a peer_connection -> session dependency on a sliding average state (this can be used for disk stats too) 2014-07-29 16:35:03 +00:00
Arvid Norberg 7c9c25e359 cleaned up redundant bytes and failed bytes counters. moved some into the stats_counters 2014-07-29 05:59:00 +00:00
Arvid Norberg ab8c1eb334 log latency of bittorrent requests 2014-07-28 22:18:06 +00:00
Arvid Norberg 2f6a68bad3 track RTT of piece requests 2014-07-28 07:52:59 +00:00
Arvid Norberg 035da93592 fixed disk_io_job flags being used as file flags 2014-07-28 01:06:00 +00:00
Arvid Norberg 118ba5e9c4 streaming fix 2014-07-26 17:48:24 +00:00
Arvid Norberg 1e48745173 another boost chrono fix 2014-07-25 16:51:13 +00:00
Arvid Norberg af0bb0abd8 fix another integer overflow issue from switching to chrono 2014-07-25 09:03:56 +00:00
Arvid Norberg b78fdc630d fix another integer overflow issue from switching to chrono 2014-07-25 08:43:52 +00:00
Arvid Norberg 2b1162aac9 fix build and suppress offsetof warnings in backwards-compatibility code 2014-07-22 05:35:05 +00:00
Arvid Norberg 805c823523 merged fixes from RC_1_0 2014-07-21 03:19:58 +00:00
Arvid Norberg 79a2744fa8 fixed issue with queued resume data saving, and fixed regression in recent disk error check changes 2014-07-21 03:03:59 +00:00
Arvid Norberg 8552e75f21 merge error code fix from RC_1_0 2014-07-20 20:49:56 +00:00
Arvid Norberg 4284606cbc merged SOCKS4 fix into trunk 2014-07-20 19:46:15 +00:00
Arvid Norberg 6bd58da567 handle EOF error on windows when checking 2014-07-20 09:27:02 +00:00
Arvid Norberg cd456964ad storage fixes 2014-07-20 08:59:02 +00:00
Arvid Norberg f3a7008bd5 close files when stopping a torrent 2014-07-20 00:23:12 +00:00
Arvid Norberg 499edabf9f a bit more cleaning up of m_ses uses in peer_connection 2014-07-19 22:33:45 +00:00
Arvid Norberg 30713a4a79 remove buffer stats debugging feature 2014-07-19 08:20:20 +00:00
Arvid Norberg f15182a737 merged changes from RC_1_0 2014-07-19 07:12:20 +00:00
Arvid Norberg 30d561d0c5 merged random_seed assert into trunk 2014-07-19 02:17:19 +00:00
Arvid Norberg d2fccd8ae7 merged resume data fix from RC_1_0 2014-07-15 03:23:43 +00:00
Arvid Norberg 65bb1d0006 pass all the arguments to peer connections as an argument pack 2014-07-14 04:32:41 +00:00
Arvid Norberg fa613131c2 removed unused session_impl member, m_next_disk_peer 2014-07-13 06:34:59 +00:00
Arvid Norberg 01640e1682 separate stats counters from session_interface (this was the main use of m_ses in peer connections) 2014-07-13 04:56:53 +00:00
Arvid Norberg 14f02a4475 fix todo comment 2014-07-13 02:47:15 +00:00
Arvid Norberg ca27c0d5ca fix another boost.chrono issue 2014-07-13 00:48:32 +00:00
Arvid Norberg bf18e310e6 remove some peer connection dependencies on m_ses 2014-07-12 22:32:55 +00:00
Arvid Norberg d16fe60ca4 some more disk io thread asserts 2014-07-12 22:09:20 +00:00
Arvid Norberg ddc406f853 mark up a few more places to make the resume-data dirty 2014-07-12 22:03:29 +00:00
Arvid Norberg c8e8eb6e15 some asserts in disk_io_thread. fix issue in torrent::initialize 2014-07-12 19:23:31 +00:00
Arvid Norberg 24b9101075 merged changes from RC_1_0 2014-07-12 06:20:16 +00:00
Arvid Norberg 374380667c make default_storage a bit more robust 2014-07-10 01:59:35 +00:00
Arvid Norberg 34440224fc merged web seed redirect fix from RC_1_0 2014-07-09 20:53:39 +00:00
Arvid Norberg 8fc07e6e89 more work towards making client_test event-driven and use session stats counters instead of session_status + some refactoring 2014-07-08 22:37:13 +00:00
Arvid Norberg 9d172a8723 fixed chrono issue in dht 2014-07-08 15:36:47 +00:00
Arvid Norberg a6f345181f fixed some unused argument warnings 2014-07-07 06:28:48 +00:00
Arvid Norberg c90285df8a restore DHT semantics to fix dht unit test 2014-07-07 00:09:05 +00:00
Arvid Norberg 7351389ce8 land libtorrent_aio branch in trunk 2014-07-06 19:18:00 +00:00
Arvid Norberg 6ef1b98717 merged compiler warning fixes from RC_1_0 2014-07-05 14:10:25 +00:00
Arvid Norberg 6c6fe4dfe2 merged fixes of warnings from RC_1_0 2014-07-04 23:40:31 +00:00
Arvid Norberg 6e275fbe21 removed left-over unused variables 2014-07-02 02:53:10 +00:00
Arvid Norberg 34737965d1 remove leftover comparison from when there was more than one proxy setting 2014-07-01 07:48:34 +00:00
Arvid Norberg fa4c016d39 fix bug in udp_socket when changing socks5 proxy quickly 2014-06-30 08:41:33 +00:00
Arvid Norberg 36e8945968 more build fixes 2014-06-29 19:11:15 +00:00
Arvid Norberg 5f4f78c383 fix build 2014-06-29 18:54:20 +00:00
Arvid Norberg 28fb774383 initialize pad files to priority 0 by default 2014-06-29 01:24:51 +00:00
Arvid Norberg 6043e14131 remove pch.hpp 2014-06-28 23:45:46 +00:00
Arvid Norberg c76e8189a6 fix windows build error 2014-06-27 02:04:37 +00:00
Arvid Norberg 91a22d48c3 fix bugs in convert_to/from_native() on windows 2014-06-25 17:43:25 +00:00
Arvid Norberg 3f4eba1bdb web seed and storage fixes 2014-06-21 06:58:39 +00:00
Arvid Norberg 8d44d87556 merge build fix from RC_0_16 2014-06-19 03:34:42 +00:00
Arvid Norberg 9c63dd1341 fix unhandled exception 2014-06-19 03:26:29 +00:00
Arvid Norberg 735916ad44 remove restrictions on pad_file_limit and alignment when creating torrents. This makes the torrent creator more flexible to create all-padded files for instance 2014-06-18 06:22:01 +00:00
Arvid Norberg b79dd1fee1 fix issue with symlink attributes 2014-06-18 06:20:12 +00:00
Arvid Norberg 5642a0bd59 fix outstanding bytes issue when receiving redundant bytes 2014-06-17 08:07:03 +00:00
Arvid Norberg 2b7bef0f7b fix support for web servers not supporting keepalive 2014-06-15 18:02:59 +00:00
Arvid Norberg 6d95b48afa only attempt to set the TOS on socket when configured 2014-06-15 17:44:27 +00:00
Arvid Norberg 20ef852461 merged upnp fix from RC_0_16 2014-06-15 17:30:40 +00:00
Arvid Norberg cb089e74ba merged UPnP fix from RC_0_16 2014-06-15 04:20:39 +00:00
Arvid Norberg 2c75acf98f add clients to identify_client 2014-06-13 17:34:15 +00:00
Arvid Norberg 6ed95d7f82 support storing save_path in resume data 2014-06-12 22:39:41 +00:00
Arvid Norberg 3f693255c8 merged lsd fix from RC_0_16 2014-06-11 16:30:34 +00:00
Arvid Norberg 6d07af3b57 merge bitfield issue fix from RC_0_16 2014-06-11 08:32:24 +00:00
Arvid Norberg 3e5ab73127 fix windows build 2014-06-09 04:08:41 +00:00
Arvid Norberg e291ab3290 minor streaming improvements 2014-06-08 21:15:34 +00:00
Arvid Norberg dd2e605796 don't use full allocation on network drives (on windows) 2014-06-07 02:57:24 +00:00
Arvid Norberg 647cda2934 merge streaming fix from libtorrent_aio 2014-06-06 15:27:44 +00:00
Arvid Norberg 2125efbbd8 merged streaming changes from libtorrent_aio into trunk 2014-06-06 01:26:18 +00:00
Arvid Norberg e8ef5cb84e documentation fixes, and remove debug dependency on file_pool structure layout 2014-05-26 01:02:26 +00:00
Arvid Norberg 3893a55a57 fix to the fix 2014-05-25 05:28:15 +00:00
Arvid Norberg 96f25d6942 attempt to fix linux build 2014-05-25 05:10:30 +00:00
Arvid Norberg 64c09e7607 support for older boost versions 2014-05-25 00:13:17 +00:00
Arvid Norberg ea77427e07 added clear_piece_deadlines() to remove all piece deadlines 2014-05-23 02:23:11 +00:00
Arvid Norberg 4deafb5e29 add workaround for GCC bug in MingW (broken support for PVOID64) and improve resiliency of storage 2014-05-23 02:09:27 +00:00
Arvid Norberg 5f98dec91b revert mistake in queuing logic 2014-05-22 22:07:01 +00:00
Arvid Norberg 283b74ae55 downloaders only consider download threshold and seeds only consider upload thresholds, for determining whether a torrent is considered inactive or not 2014-05-18 23:42:10 +00:00
Arvid Norberg a1e7d3229d improve queuing logic of inactive torrents (dont_count_slow_torrents) 2014-05-18 22:17:51 +00:00
Arvid Norberg 3e25e56f0e fix initialization order warning 2014-05-12 07:57:58 +00:00
Arvid Norberg 5b89c3f5f9 merged some of steven siloti's changes. expose optimistic unchoke logic to plugins 2014-05-12 07:28:34 +00:00
Arvid Norberg b16dc66df2 using certificates from buffers instead of files is only available in boost 1.54 and later 2014-05-12 04:30:19 +00:00
Arvid Norberg 8a132cb9ca fix int64_t -> boost::int64_t and run distcheck on build_dist.sh script 2014-05-11 08:20:42 +00:00
Arvid Norberg 330d46a4c6 makefile fixes (and add missing upnp.xml file) 2014-05-11 03:14:53 +00:00
Arvid Norberg 22491740e5 fix the fix for large UDP packets on windows 2014-05-10 23:44:57 +00:00
Arvid Norberg 870073345b merged sparse file fix from RC_0_16 2014-05-10 23:38:54 +00:00
Arvid Norberg aef1335e76 add overload to set certificate by buffer, not just by path to a file 2014-05-10 21:53:50 +00:00
Arvid Norberg 35141733fb remove some old unmaintained example code. make examples depend less on libtorrent internals 2014-05-10 20:20:57 +00:00
Arvid Norberg 9cc7c3bbf9 if issue with large UDP packets on windows 2014-05-10 06:37:31 +00:00
Arvid Norberg e225259481 fix some msvc warnings 2014-05-10 03:23:05 +00:00
Arvid Norberg 68b2679a16 move string_tokenize out of i2p_stream and add unit test for it 2014-05-04 22:40:30 +00:00
Arvid Norberg e0e5a55f10 factor out error handling in lazy_bdecode 2014-05-04 20:47:16 +00:00
Arvid Norberg 555efd9279 factor out address/endpoint I/O into it's own unit test. merge write_string from bencode and socket_io. extend unit test 2014-05-04 06:46:47 +00:00
Arvid Norberg e5a9a6b36f make xml_parse not be a template 2014-05-03 21:10:44 +00:00
Arvid Norberg 474e77039f removed set_ratio feature 2014-05-03 17:11:55 +00:00
Arvid Norberg 52463ddd1d fix inflate_gzip export for unit test 2014-05-03 07:57:36 +00:00
Arvid Norberg 0ed91e248f leverage boost's endian detection in sha1-implementation 2014-05-03 03:45:51 +00:00
Arvid Norberg 43c41ddfb1 fixed bug in gunzip 2014-05-02 16:11:25 +00:00
Arvid Norberg 78565e95ce fix darwin clang build 2014-05-02 07:15:47 +00:00
Arvid Norberg e19c52ec98 improve lazy_bdecode test to cover more error cases 2014-05-01 03:54:47 +00:00
Arvid Norberg ab96600ae3 fix dht assert 2014-04-29 21:31:25 +00:00
Arvid Norberg 7d1de6215a improve error recovery in lazy bdecoder 2014-04-23 00:25:55 +00:00
Arvid Norberg f037704539 clean up peer-id in bt_peer_connection (for privacy mode) and reduce dependency on session 2014-04-22 23:37:21 +00:00
Arvid Norberg 3192e59a1a improve piece_deadline/streaming 2014-04-22 04:21:14 +00:00
Arvid Norberg 15d4a0c55c merged stats fix from RC_0_16 2014-04-18 06:27:54 +00:00
Arvid Norberg 0b3df1c973 merged integer overflow fix from RC_0_16 2014-04-16 08:25:14 +00:00
Arvid Norberg 2798c8d345 merge F_SETLF change from RC_0_16 2014-04-16 07:43:36 +00:00
Arvid Norberg b0996ef855 merged fix from RC_0_16 2014-04-16 07:12:30 +00:00
Arvid Norberg 9e94a73ddd support web seeds in magnet links 2014-04-15 09:31:28 +00:00
Arvid Norberg 1afa9db689 merged proxy fix for adding .torrent file by URL from RC_0_16 2014-04-06 05:07:10 +00:00
Arvid Norberg a15388df5f back-port shutdown assert fix 2014-04-06 01:03:01 +00:00
Arvid Norberg 290ce566b0 fix resume file issue related to daylight savings time on windows 2014-04-04 07:30:54 +00:00
Arvid Norberg 91799025f2 merged bdecode fix from RC_0_16 2014-04-04 03:21:15 +00:00
Arvid Norberg 569ce0a965 honor pieces with priority 7 in sequential download mode 2014-04-03 02:03:14 +00:00
Arvid Norberg 1734beda07 add missing includes for debug logging builds 2014-03-28 01:55:09 +00:00
Arvid Norberg 140ed20c93 fix stats bug 2014-03-25 09:17:48 +00:00
Arvid Norberg 6f0a7f3f3b fix valgrind build issue 2014-03-25 07:19:21 +00:00
Arvid Norberg 87a05814e5 fix msvc-7.1 build 2014-03-24 07:42:55 +00:00
Arvid Norberg fa2ea57e43 expand buffer sizes for upnp error messages 2014-03-23 22:49:09 +00:00
Arvid Norberg 946aecdb59 fixed some warnings 2014-03-23 19:13:21 +00:00
Arvid Norberg 682ceff21b improve messaging of assert caused by precondition violation 2014-03-23 07:40:43 +00:00
Arvid Norberg c6b68ab683 fix warning 2014-03-23 01:41:00 +00:00
Arvid Norberg 6120b78704 merged python fixes from RC_0_16 2014-03-23 00:49:58 +00:00