Commit Graph

294 Commits

Author SHA1 Message Date
Arvid Norberg 3f90501934 add support for IPv6 peers from udp trackers (#1802)
add support for IPv6 peers from udp trackers
2017-03-11 02:46:51 -05:00
Alden Torres 1ab1b98138 optimized dht_get_peers_reply_alert storage and created alerts unit test (#1714)
optimized dht_get_peers_reply_alert storage and created alerts unit test
2017-02-18 00:13:46 -05:00
Arvid Norberg 6a701437b6 use strong_typedef for peer_class_t type (#1595)
use strong_typedef for peer_class_t type
2017-01-21 22:40:19 -05:00
Arvid Norberg 3d06371f31 factor out some common storage utilities out of storage.cpp (#1515)
factor out some common storage utilities out of storage.cpp
2017-01-11 00:42:10 -05:00
Pavel Pimenov 6afb1f3e83 aux::to_hex(sha1) -> sha1.to_hex() (#1418)
generate hex strings into std::string instead of stack-allocated char arrays
2016-12-22 10:44:36 -05:00
Arvid Norberg 3f1084d63d strengthened type safety in handling of piece and file indices (#1409)
strengthened type safety in handling of piece and file indices
2016-12-22 10:42:33 -05:00
arvidn 20aeed09e1 clean up tests 2016-11-12 17:39:34 -05:00
arvidn 583082a3a0 merged RC_1_1 into master 2016-11-09 19:53:55 -05:00
arvidn 200b3c4965 add rename file test 2016-11-05 15:20:38 -04:00
Steven Siloti f5366bd816 use span for scatter/gather lists (#1260)
use span for gather/scatter buffers. remove explicit size parameter from file_op
2016-10-26 20:40:56 -04:00
Alden Torres ded3ed6abf refactor in alert types to use more const fields and more clear API (#1222)
refactor in alert types to use more const fields and more clear API
2016-10-19 01:32:15 -04:00
arvidn 6c805bd06d simplify print statements in tests 2016-10-09 20:23:45 -04:00
arvidn 9453fbd54b merged RC_1_1 into master 2016-10-09 20:09:44 -04:00
Arvid Norberg 6bb2d7c017 Sanitize 1.1 (#1197)
enable address sanitizer
2016-10-09 17:00:20 -04:00
Alden Torres 6c31ea3d44 created dht state and session params refactor (#1100)
created dht state and session params refactor
2016-09-17 09:42:04 -04:00
Alden Torres 01e9810f7a more boost types cleanup and handling of deprecated macos libcrypto (#1072)
more boost types cleanup and handling of deprecated macos libcrypto. more granular TORRENT_MACOS_DEPRECATED_LIBCRYPTO
2016-09-07 17:51:18 -04:00
Alden Torres bb388563b3 refactor to use torrent_info with std::shared_ptr (#1006) 2016-08-17 17:26:35 -04:00
arvidn 8c8c3d5587 replace boost::function with std::function 2016-08-13 07:07:26 -04:00
Arvid Norberg 71f5510d62 make the random function produce proper random distributions, based o… (#981)
make the random function produce proper random distributions, based on uniform_int_distribution of C++11. also clean up piece_picker's priority_range to return two results instead of taking pointers to out-parameters. fix recent pe-crypto regression exposed by this change
2016-08-06 13:18:48 -04:00
Alden Torres f795e88789 don't define _WIN32_WINNT if not under windows 2016-07-30 18:03:06 -04:00
arvidn 83dba91168 use span for to_hex and from_hex functions 2016-07-29 18:42:18 -04:00
Arvid Norberg 7bf49c0a1c modernize hasher to use array_view (#931)
modernize hasher to use array_view as well as adding array_view support to entry
2016-07-22 07:29:39 -07:00
Arvid Norberg e72f95e0d9 fix test_remap_files (#905)
fix test_remap_files
2016-07-15 14:35:57 -04:00
Arvid Norberg e801d2e6de modernize replace deprecated headers (#897) 2016-07-09 23:17:55 -04:00
Arvid Norberg 770935cd46 modernize-use-nullptr (#894) 2016-07-09 16:26:26 -04:00
Arvid Norberg eda956f13a use standard library for suspending threads (#855)
use standard library for suspending threads
2016-06-26 09:24:06 -04:00
Arvid Norberg 6aabe3762b general modernization (#836)
general modernization. use nullptr instead of NULL, use std::tuple instead of boost::tuple, transition some unordered set/map from boost to std. some clean-up of includes
2016-06-20 11:32:06 -04:00
Arvid Norberg 717ed8bd3b Msvc warnings (#822)
fix msvc warnings in python bindings and simulations
2016-06-18 19:24:27 -04:00
Arvid Norberg ed077c8358 use cstdint intead of boost/cstdint.hpp (#833)
use cstdint intead of boost/cstdint.hpp
2016-06-18 14:01:38 -04:00
Arvid Norberg ef1a24518d fix dht tests (#803)
fix tests
2016-06-11 15:37:28 -04:00
Arvid Norberg fa8232cd13 remove some old cruft and defines (#785)
remove some old cruft and defines
2016-06-04 10:03:13 -04:00
Arvid Norberg 8c8f5bb03b deprecated public to_hex() and from_hex() functions (#784) 2016-06-04 10:01:43 -04:00
Arvid Norberg 96999ad67f replace uses of boost::bind with std::bind and lambdas (#745) 2016-05-25 00:31:52 -04:00
Arvid Norberg 748af6eec1 general cleanup. remove valgrind markup, log_hash_failures and C headers (#752)
general cleanup. remove valgrind markup, log_hash_failures and C headers
2016-05-23 08:15:39 -04:00
Arvid Norberg e8380e1d0b factor out includes from config.hpp into the files actually using it. primarily, printf family of functions, since C++11 version is used now. This removes the need for an snprintf-wrapper on windows (#732) 2016-05-17 09:24:06 -04:00
Arvid Norberg 20b41ad0b9 Threads (#671)
use std::thread, std::mutex, std::condition_variable instead of pulling them in from boost.asio internals.
2016-04-30 18:54:23 -04:00
Arvid Norberg 3c785b96fc Merge pull request #268 from ssiloti/dht-ipv6
Support DHT over IPv6
2016-04-25 19:19:48 -04:00
Andrei Kurushin 62eb956c54 fix x64 build with VS2015 UP2 compiler (#640)
fix VS2015 compiler warnings for: address-model=64, deprecated-functions=on, link=shared
2016-04-25 17:22:09 -04:00
Steven Siloti 43be11177b Add dual stack DHT node simulation tests 2016-04-24 14:26:57 -07:00
arvidn fb85e5e60f improve message from listen_failed_alert. Post listen_failed_alert for every failure, including the ones that are re-tried 2016-03-13 16:18:44 -04:00
arvidn d748a59029 attempt to fix test_transfer 2016-02-23 19:13:14 -05:00
arvidn d91054b8f1 forward port fix to ip_voter from RC_1_0 2016-02-09 19:09:53 -05:00
arvidn dd48faa8d4 minor debug logging issue in test facility wait-for-alert and fix minor shutdown issue with udp_socket packet subscription 2016-02-08 02:05:00 -05:00
arvidn 15ec839d33 extend the unit test of dht_storage 2015-12-19 02:09:06 -05:00
arvidn 06b648203f clean up use of error categories 2015-11-24 00:50:51 -05:00
arvidn ebb9fdaf54 add error_code to torrent_status instead of error string 2015-11-05 20:43:23 -05:00
arvidn 5da511f140 now that force-started torrents aren't affected by the auto-manager, they need to be explicitly kicked when entering checking state (it would be nice if all this could be done through set_state()) 2015-09-29 20:49:38 -04:00
Alden Torres 197a443465 Fix of dht_storage_counters::peers counter. 2015-09-24 10:50:04 -04:00
arvidn b628692223 separate out announce_entry and torrent_status into their own headers 2015-09-18 08:08:08 -04:00
arvidn e3591c3a1c attempt to log more and potentially fix wait_for_downloading in unit tests 2015-08-30 08:52:58 -04:00
arvidn 24b20a59cd remove some randomness from the unit tests 2015-08-13 02:06:30 -04:00
arvidn 2739def57f minor cleanups. use libtorrent typedefs for asio. failing to bind IPv6 UDP socket is no longer fatal. removed some redundant listen_failed_alerts 2015-07-11 23:01:27 -04:00
arvidn 3b83c5418c attempt to make starting proxy server for tests more reliable 2015-06-24 20:51:23 -04:00
arvidn 9fc4968dc4 attempt to make start_web_server more robust in the tests 2015-06-22 23:55:47 -04:00
arvidn adc63d2b88 improve random entropy when picking port for web_server in test 2015-06-20 14:11:03 -04:00
arvidn c1913a97f3 attempt to make setup_transfer more reliable by waiting for torrents to transition to downloading state before connecting peers 2015-06-15 22:00:02 -04:00
arvidn 0d6e65ec24 improve reliability of some of the unit tests 2015-06-10 01:22:01 -04:00
arvidn b5a477d7fd split up some more tests into smaller test cases for easier diagnosing 2015-06-06 02:42:23 -04:00
arvidn 48bc00cbb7 attempt to make unit tests more deterministic 2015-06-05 23:02:07 -04:00
Arvid Norberg f9c9d0ad0d merge small unit tests to make running the tests quicker. expand the test framework a bit. add ax_boost_random.m4 script to link against boost.random correctly from makefile. 2015-05-30 04:31:23 +00:00
Arvid Norberg 71ee44ae5e fix build issue, some warnings 2015-05-17 23:32:13 +00:00
Arvid Norberg 5dc00969f8 fix more warninigs 2015-05-06 02:13:03 +00:00
Arvid Norberg f7e4f83469 separate out session_stats into its own header. silences warning and cleans up 2015-04-25 02:12:02 +00:00
Arvid Norberg 3ea67e2bf5 move time_now_string out to the unit test library (basically unused in libtorrent itself) 2015-04-24 03:48:08 +00:00
Arvid Norberg 013ed36f09 landed alert_queue feature branch into trunk 2015-04-03 20:15:48 +00:00
Arvid Norberg 0aece517ce fix some undefined behavior in tests. and fix test_file_storage 2015-03-22 05:31:55 +00:00
Arvid Norberg 74ca290fe6 attempt to fix build 2015-03-15 06:05:41 +00:00
Arvid Norberg 881fa4dce6 remove sleep() from the libtorrent API 2015-03-13 05:52:48 +00:00
Arvid Norberg 6c1df7eb55 landed the bdecode branch in master. lazy_bdecode/lazy_entry is now being replaced by bdecode/bdecode_node 2015-03-12 05:20:12 +00:00
Arvid Norberg c1dc982f4f deprecate the ptime type and related time types. just use boost::chrono / std::chrono 2015-03-12 04:34:54 +00:00
Arvid Norberg b897a6ce29 fix bug in settings_pack causing intermittent unit test failures. added unit test to cover the bug 2015-01-03 16:52:22 +00:00
Arvid Norberg 764b09d6b5 make the peer fingerprint a regular setting and remove it from the main session constructor argument list 2014-12-31 15:51:45 +00:00
Arvid Norberg 1ed1963f29 remove size_type typedef in favor of boost::int64_t 2014-12-03 04:32:50 +00:00
Arvid Norberg 14c9bd90d3 fix bug in setup_transfer (for unit tests). fix verbose logging build. make sure test_pex is reliable 2014-10-21 02:08:46 +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 bed6d5c233 fix test builds without deprecated functions 2014-09-03 03:17:47 +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 7351389ce8 land libtorrent_aio branch in trunk 2014-07-06 19:18:00 +00:00
Arvid Norberg 2b7bef0f7b fix support for web servers not supporting keepalive 2014-06-15 18:02:59 +00:00
Arvid Norberg e225259481 fix some msvc warnings 2014-05-10 03:23:05 +00:00
Arvid Norberg f3535b1e69 another msvc-7.1 fix 2014-03-25 04:13:58 +00:00
Arvid Norberg e332167ddd improve storage unit tests 2014-03-07 08:39:55 +00:00
Arvid Norberg 9f4e865596 merge remap_files unit test from RC_0_16 2014-03-05 09:37:49 +00:00
Arvid Norberg 0a042dde8b clean up udp-tracker unit tests 2014-02-23 01:32:55 +00:00
Arvid Norberg 6c22d426d4 make all unit tests pass msvc's /RTCc instrumentation (no implicit integer truncation in casts) 2014-02-05 09:38:32 +00:00
Arvid Norberg 36c9add067 don't print stuff to stdout in debug builds. when waking up from completing a connection attempt, exit immediately if the connection is disconnecting, or disconnect if we're in graceful pause mode. some test cleanups 2014-01-26 08:18:13 +00:00
Arvid Norberg 99d9916c29 some more piece_picker asserts 2014-01-22 09:53:47 +00:00
Arvid Norberg dca3f3c1a8 improve SSL error reporting and fix torrent_info::ssl_cert() bug 2014-01-20 01:01:03 +00:00
Arvid Norberg ad772aecd8 test tweaks 2013-12-16 05:50:03 +00:00
Arvid Norberg d64d12e50d merge test_read_piece from RC_0_16 2013-11-24 01:32:51 +00:00
Arvid Norberg b4aad2a481 move web_server for unit tests over to python 2013-11-03 08:15:51 +00:00
Arvid Norberg 4e78921c76 more debug output for test web server 2013-10-28 07:56:10 +00:00
Arvid Norberg 9ec2f48a6e split out test_priority from test_transfer 2013-10-10 17:00:32 +00:00
Arvid Norberg 28041accc1 unit test cleanup (test_metadata_transfer) 2013-10-10 07:50:34 +00:00
Arvid Norberg d45d193811 improve error message for tracker_error_alert. various smaller attempts at making the unit tests more reliable 2013-10-07 06:20:55 +00:00
Arvid Norberg 793c65cc61 attempt to fix test http proxy to handle EAGAIN errors 2013-10-07 00:34:06 +00:00
Arvid Norberg d90f7336b1 fix unit test web server for tracker announces 2013-10-07 00:33:55 +00:00
Arvid Norberg 0e7fb25916 disable debug output in test web server 2013-10-01 22:18:13 +00:00
Arvid Norberg 6dcac0a33f minor unit test fixes 2013-10-01 16:47:05 +00:00
Arvid Norberg d327916c27 fix bug in port randomization in unit tests 2013-10-01 04:30:15 +00:00