Arvid Norberg
b74bdfa7db
make dht logging deterministic ( #1460 )
...
make dht logging deterministic (ues an id instead of this-pointer to identify a traversal algorithm)
try with more DHT nodes
2016-12-27 07:12:57 -08:00
Andrei Kurushin
1ec5c69dcd
minor code corrections ( #1430 )
...
use compact span cast. extend split_path api with only_first_part flag. use single loadlibrary and getprocaddress for IP helper
2016-12-26 22:45:48 -08:00
arvidn
2f75dcccfe
on backwards compatible set_settings(), stack allocate settings_pack
2016-12-26 22:44:42 -08:00
arvidn
192ef4962b
simplify the buffer_allocator_interface
2016-12-26 08:36:50 -08:00
arvidn
cda715c152
introduce type for slot index in part_file
2016-12-26 08:33:19 -08:00
Arvid Norberg
42a27b3ebc
introduce a prio_index_t type ( #1453 )
...
* introduce a prio_index_t type for indexing into the priority sorted piece list, m_pieces, in piece_picker
* some piece picker simplification
* fix msvc warning for prio_index_t
2016-12-26 08:25:50 -08:00
Falcosc
6520fcebf1
fix session invariant check fail for difficult setting dependencies ( #1449 )
...
clean up session_impl invariant checks
2016-12-26 08:09:52 -08:00
arvidn
5ed0086b51
removed mmap_cache feature
2016-12-25 21:12:49 -08:00
arvidn
6be7bb9eb7
clean up some piece/file priority code
2016-12-24 11:26:09 -08:00
Pavel Pimenov
c34a2541cc
Log refactoring ( #1446 )
...
factor out common logging code in some dht traversal algorithms
2016-12-24 06:46:21 -08:00
Alden Torres
71b5d9fb85
fixed Wrange-loop-analysis warning with Apple clang-800.0.42.1 ( #1440 )
...
fixed Wrange-loop-analysis warning with Apple clang-800.0.42.1
2016-12-23 06:07:37 -05:00
arvidn
3f612d7e99
cleaning up of left-overs from torrent eviction functionality
2016-12-23 06:06:59 -05:00
Alden Torres
c1a2e7290c
added explicit time_t cast to avoid warnings in android 32 bits
2016-12-22 21:24:25 -05:00
Alden Torres
75f307c187
minor cleanup and refactor in peer connection
2016-12-22 17:48:47 -05:00
Alden Torres
c672467331
added one more shorten-64-to-32 warning fix, added more std::
2016-12-22 13:48:13 -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
93f400265b
revert change to use std::time_t (mingw64 has abi issues)
2016-12-22 01:13:17 -05:00
arvidn
cde9457fdb
fix merge issue
2016-12-22 01:13:17 -05:00
arvidn
a2c4e7490e
merged RC_1_1 into master
2016-12-20 01:16:13 -05:00
arvidn
ad7e796d05
fix socks5 support for UDP. based on patch in https://github.com/arvidn/libtorrent/issues/1373
2016-12-19 23:52:53 -05:00
Falcosc
8adcbdd32b
add setting urlseed_max_request_bytes to handle large web seed requests #1405 ( #1423 )
...
add setting urlseed_max_request_bytes to handle large web seed requests. change default for urlseed max request to 16MIB
2016-12-18 15:58:14 -05:00
Alden Torres
eaf99aa42b
fixed more warnings of shorten-64-to-32 and sign-compare in android ( #1425 )
...
fixed more warnings of -Wshorten-64-to-32 in android. changed file_status to use std::time and disable warnings of NLMSG_OK in clang
2016-12-18 10:59:41 -05:00
Andrei Kurushin
d62b980278
backport fix upnp xml_parse
2016-12-18 09:01:33 -05:00
Andrei Kurushin
10e3847b40
fix upnp ( #1421 )
...
* fix upnp xml_parser, and listen sockets remap
2016-12-17 17:50:03 -05:00
Alden Torres
1b808b6516
refactor in aux::write_ to avoid explicit castings ( #1426 )
...
refactor in aux::write_ to avoid explicit casts
2016-12-17 15:03:43 -05:00
arvidn
814f7363a4
deprecate identify_client() and fingerprint type
2016-12-17 11:48:20 -05:00
Steven Siloti
db65eaaa00
submit disk jobs from read_piece right away
...
Without this the jobs get submitted on the next tick which may take a while.
2016-12-17 02:23:09 -05:00
Steven Siloti
916fc92c49
create separate function for reading a node from a list
2016-12-17 02:22:13 -05:00
Alden Torres
f715ebfd97
header fix and refactor in udp_tracker_connection and typos in lazy_entry
2016-12-17 02:20:29 -05:00
Alden Torres
139528aae4
code refactor in torrent.cpp for more auto loop and formatting
2016-12-17 02:12:23 -05:00
Alden Torres
22b596945e
enable /W4 warnings for msvc
2016-12-13 19:36:14 -05:00
Alden Torres
63df1a26b6
changelog note, typos and .gitignore
2016-12-13 08:11:09 -05:00
Alden Torres
f382936d56
headers, end of file, code cleanup
2016-12-12 23:36:45 -05:00
arvidn
51fb7feeb7
fix issue when skipping missing files during fill checks
2016-12-12 23:32:55 -05:00
Alden Torres
a05f0ba8a4
refactor for more modern struct initialization and use of api
2016-12-12 02:15:27 -05:00
Steven Siloti
ca07ee83a3
mark all converstion to bool operators as explicit
2016-12-12 01:34:36 -05:00
Alden Torres
d9f8d4b642
refactor to more use of auto c++11 keyword ( #1404 )
...
refactor to more use of auto c++11 keyword
2016-12-11 20:50:30 -05:00
Alden Torres
21fb0e8c20
making tracker_manager::remove_request type specific
2016-12-11 14:20:37 -05:00
Alden Torres
3a92908f39
formatting, added std:: and spaces
2016-12-10 23:11:43 -05:00
Alden Torres
dd7179fb10
added a few consts to arguments and local variables
2016-12-10 18:19:14 -05:00
arvidn
bbfe58d03c
fix bind-to-device for UDP sockets
2016-12-10 18:18:54 -05:00
Alden Torres
6b70ac1f77
improved port reading in lsd, minor code refactor
2016-12-10 12:18:31 -05:00
Alden Torres
e73435a77b
fixed shorten-64-to-32 warnings for clang
2016-12-10 08:57:08 -05:00
Alden Torres
7266b0b360
fixing shorten-64-to-32 warnings, part 4
2016-12-09 17:24:07 -05:00
Alden Torres
123a6389cd
minor refactor in torrent_status and minor header cleanup in torrent_handle
2016-12-09 17:18:03 -05:00
Pavel Pimenov
d8b413c771
Fix c4996 strcpy ( #1395 )
...
use std::memcpy() instead of std::strcpy()
2016-12-09 17:17:27 -05:00
Steven Siloti
30303c17df
don't indicate interest in peers when in upload only mode
...
If the torrent is paused we don't want to mark peers as interesting
even if the torrent has not finished downloading.
2016-12-09 17:16:25 -05:00
Alden Torres
e1dcf82e2a
fixing shorten-64-to-32 warnings, part 3
2016-12-08 20:22:34 -05:00
Steven Siloti
5d0322d393
fix assertion in fingerprint::to_string
2016-12-07 20:52:45 -05:00
Alden Torres
4142dfe5eb
headers and code cleanup in udp_socket code
2016-12-06 22:54:29 -05:00
Alden Torres
ffdf5c0f5d
avoid unnecessary creation of strings in create_torrent
2016-12-06 22:53:55 -05:00
Alden Torres
0625606230
fixing shorten-64-to-32 warnings, part 2
2016-12-06 22:53:41 -05:00
Alden Torres
553cff97fb
minor fix of the use of TORRENT_USE_I2P
2016-12-06 00:39:27 -05:00
Alden Torres
37cbdc5b37
fixing shorten-64-to-32 warnings, part 1
2016-12-05 00:22:17 -05:00
arvidn
864fcfaced
initialize piece priorities to 4
2016-12-04 18:36:45 -05:00
Steven Siloti
b9169609df
support separate external ip for each interface ( #1383 )
...
support separate external ip for each interface
2016-12-04 15:58:51 -05:00
arvidn
8874a907ef
fix to file priorities
2016-12-03 00:57:52 -05:00
Alden Torres
69eff36a52
passing block size to smart_ban plugin methods for hashing
2016-12-02 18:08:04 -05:00
arvidn
09b5cfd688
remove build option to use narrower types in piece_picker (optimize_memory_usage)
2016-11-29 08:11:51 -05:00
Pavel Pimenov
e3c5a639ca
Add bt_peer_connection::write_dht_port() ( #1360 )
...
add void bt_peer_connection::write_dht_port()
2016-11-29 08:11:13 -05:00
Pavel Pimenov
ee61d5c308
Small optimisation identify_client ( #1361 )
...
small optimisation identify_client
2016-11-29 01:01:00 -05:00
arvidn
0f38acf829
don't send dht-port if we don't have a udp listen socket
2016-11-27 21:22:11 -05:00
arvidn
6579ae1994
fix listen_failed_alert socket_type report bug
2016-11-27 21:22:11 -05:00
Alden Torres
d5c4cd7280
fixed sign-compare warnings and some refactor ( #1354 )
...
fixed sign-compare warnings and some refactor. make sequence_number backed by std::int64_t
2016-11-27 08:46:53 -05:00
Arvid Norberg
0df9d1c641
upgrade some C-arrays to std::array in escape_string.cpp ( #1357 )
...
upgrade some C-arrays to std::array in escape_string.cpp
2016-11-26 23:38:25 -05:00
Arvid Norberg
54f052a97b
allocation slot type ( #1352 )
...
use a specialized type for allocation slot indices
2016-11-26 03:09:01 -05:00
Arvid Norberg
15ab8f387b
cleaning up of disk_interface and improving type safety ( #1353 )
...
cleaned up disk_interface and improved type safety. removed unused disk status code disk_check_aborted, and removed status code return value for async_hash
2016-11-26 01:51:47 -05:00
Alden Torres
c30027e4a1
more integral type conversion warning fixes, now only needs shorten-64-to-32 ( #1349 )
...
more integral type conversion warning fixes, now only needs shorten-64-to-32
2016-11-25 11:17:25 -05:00
arvidn
1d5f42d6d0
convert remaining disk io jobs
2016-11-23 19:02:05 -05:00
arvidn
f08501b869
update callback interface for async_check_files and async_flush_piece
2016-11-23 19:02:05 -05:00
arvidn
d8662533d5
update callback signature for async_move_storage and async_release_files
2016-11-23 19:02:05 -05:00
arvidn
fc9dabe1ab
start chipping away at removing disk_io_job from the disk_interface
2016-11-23 19:02:05 -05:00
Steven Siloti
06c53a41d1
revisions based on code review
...
Moved the logic to determine which sockets to keep to a separate function and
add unit tests for it.
Store the port which was originally specified for a listen socket so that we
can match sockets reliably even with port retries.
2016-11-23 01:09:05 -05:00
Steven Siloti
babb93fb1e
keep old listen sockets if they're still valid
...
This is to support multi-home. We need to be able to keep track of which socket
a DHT node or UTP connection should use. We also need to generate notifications
when local endpoints come and go so that the DHT tracker knows when to create
or delete nodes. The easiest way to do this is to keep the same socket for as
long as its local endpoint is valid. This way the nodes and connections can
simply reference the socket itself and generating notifications is trivial.
2016-11-23 01:09:05 -05:00
Steven Siloti
07650c8558
set scope id when enumerating IPv6 addresses
...
This is necessary to be able to correctly match enumerated addresses
with those stored in listen_socket_t::local_endpoint when there is a
non-default zone id.
2016-11-23 01:09:05 -05:00
Alden Torres
86251adb1b
more fixes of integral type conversion warnings
2016-11-21 20:22:18 -05:00
Alden Torres
84e0362180
more fixes in signed compare warnings ( #1345 )
...
more fixes in signed compare warnings
2016-11-21 01:49:56 -05:00
arvidn
0e33e62627
merged RC_1_1 into master
2016-11-20 11:18:16 -05:00
arvidn
d5b76d2237
move block_cache_reference out of disk_io_job header
2016-11-20 10:34:42 -05:00
arvidn
35126576ca
remove use of disk_io_job from buffer_holder
2016-11-20 10:34:42 -05:00
arvidn
5b3a730b1f
steps towards removing disk_io_job from disk_interface
2016-11-20 10:34:42 -05:00
arvidn
4df1ecbe25
re-enable some warnings and fix code
2016-11-20 01:05:16 -05:00
Arvid Norberg
13d9361da1
don't allocate handlers for proxy sockets in the heap, move them instead ( #1342 )
...
don't allocate handlers for proxy sockets in the heap, move them instead
2016-11-19 22:56:34 -05:00
Alden Torres
a59350687a
fixed a few warnings related to signed/unsigned conversions ( #1338 )
...
fixed a few warnings related to signed/unsigned conversions
2016-11-19 21:14:16 -05:00
Andrei Kurushin
998daf6e0e
fix windows-version=xp build ( #1327 )
...
fix sha512 support for windows xp, pre sp3
2016-11-19 11:07:33 -05:00
tnextday
b25ea5329f
updates `m_last_sent` in `peer_connection::setup_send()` instand of `peer_connection::keep_alive()`
2016-11-19 02:03:12 -05:00
Alden Torres
5490f802ec
fixed warning non-virtual-dtor and minor code refactor ( #1324 )
...
fixed warning non-virtual-dtor and minor code refactor
2016-11-18 08:21:42 -05:00
Alden Torres
4c7e24ea35
more use of std::make_shared, fixing warnings of over-aligned
2016-11-18 00:28:29 -05:00
Andrei Kurushin
0a31e26344
fix logging=off build
2016-11-16 23:14:28 -05:00
Alden Torres
9e1305ed75
auto loop, consts and minor cleanup refactor
2016-11-15 19:54:38 -05:00
Andrei Kurushin
c4f1a928a4
fix i2p=off build
2016-11-15 19:48:14 -05:00
arvidn
14236993ea
collapse logic in piece_manager into storage directly
2016-11-13 02:53:16 -05:00
Alden Torres
2b58cb9de3
using std instead of boost for integral types and some headers cleanup
2016-11-12 21:22:59 -05:00
arvidn
ccd539f977
pull check resume data logic out of piece_manager into disk_io_thread and simplify it
2016-11-12 18:03:18 -05:00
arvidn
c9333849e6
deprecate relative times in torrent_status, replaced by std::chrono::time_point
2016-11-12 17:37:10 -05:00
arvidn
bba121d010
fix recent regression causing potential duplicate add_torrent_alerts
2016-11-12 01:03:38 -05:00
arvidn
e447a50c9d
use enum class in udp_tracker_connection
2016-11-11 21:39:54 -05:00
arvidn
583082a3a0
merged RC_1_1 into master
2016-11-09 19:53:55 -05:00
arvidn
f33d1b32e3
add trackers from add_torrent_params/magnet links to separate tiers
2016-11-09 18:44:01 -05:00
Alden Torres
1a159666ff
some refactor in ip change notifier source code ( #1301 )
...
some refactor in ip change notifier source code. using NETLINK_ROUTE (value 0) as the default nl_family
2016-11-08 03:44:43 -05:00
Steven Siloti
e589e342ef
reopen listen sockets when the system's IP changes ( #1299 )
...
reopen listen sockets when the system's IP changes. Only Linux and Windows supported for now.
2016-11-07 07:40:09 -05:00
arvidn
11ca69b9fc
simplify disk_io_thread interface by setting the number of threads via settings rather than a separate function
2016-11-06 23:07:09 -05:00
arvidn
3ff89f29d7
remove explicit ticking of storage from the torrent. instead make the disk_io_thread do it automatically
2016-11-06 10:26:10 -05:00
arvidn
c72053a75c
remove unused clear_read_cache function
2016-11-05 21:39:45 -04:00
arvidn
2a999e1ea7
merge RC_1_1 into master
2016-11-03 23:58:35 -04:00
Arvid Norberg
f5c7a49d61
remove incorrect deleted-storages assert and add some more test coverage in test_metadata_extensions ( #1286 )
2016-11-03 19:39:42 -04:00
arvidn
d91f6f8c05
merged RC_1_1 into master
2016-11-03 01:19:38 -04:00
Alden Torres
aef614a74c
fix build warnings/errors, typos and minor cleanup ( #1277 )
...
fix build warnings/errors, typos and minor cleanup. no need to provide boost::throw_exception, better left it to the user
2016-11-02 01:03:12 -04:00
Arvid Norberg
09cbd0a51d
remove deprecated disk_io_thread operations ( #1284 )
2016-11-02 01:01:27 -04:00
Arvid Norberg
b61ebca14a
moved async-load-torrent feature out of disk-io-thread ( #1282 )
...
moved async-load-torrent feature out of disk-io-thread into a generic worker thread
2016-11-02 01:01:04 -04:00
Arvid Norberg
1c2a8fb96e
move coalescing of reclaim block from disk_io_thread to session_impl ( #1281 )
2016-10-31 23:48:30 -04:00
Arvid Norberg
21d05945f2
documentation and deprecation fixes ( #1275 )
...
documentation and deprecation fixes
2016-10-31 20:00:01 -04:00
Arvid Norberg
8daa200d11
simplify interaction with disk_io_thread by removing the uncork interface ( #1271 )
...
simplify the interaction with the disk_io_thread by removing the uncork interface. This should be turned into a transparent part of peer_connection instead and remove cork logic from peer_connection
2016-10-30 18:21:07 -04:00
arvidn
b97bb84a9f
merge RC_1_1 into master
2016-10-29 14:25:57 -04:00
Arvid Norberg
7476f7875e
don't check file-sizes resume data for files that likely is in the partfile ( #1268 )
2016-10-29 13:53:24 -04:00
Arvid Norberg
d1a59879cb
deprecate mmap_cache ( #1269 )
...
deprecated mmap_cache feature
2016-10-29 13:42:42 -04:00
Alden Torres
dac0b9ec64
more use of nullptr, minor refactor and formatting ( #1267 )
2016-10-28 12:28:27 -04:00
arvidn
500bb24dba
merged RC_1_1 into master
2016-10-26 23:30:58 -04:00
Arvid Norberg
5f3c52f406
transition to more default member initializers ( #1261 )
2016-10-26 20:41:57 -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
6751a1eeb1
removed spaces in template types and more c++11 auto/loop refactor
2016-10-26 00:08:00 -04:00
Alden Torres
4eebd0c68a
minor refactor, compilation fix when DEBUG_DISK_THREAD and missing convert_to_native ( #1256 )
2016-10-25 20:46:23 -04:00
Arvid Norberg
61af222d92
add utility function for generating peer ID fingerprint ( #1249 )
...
add utility function for generating peer ID fingerprint
2016-10-25 08:03:26 -04:00
Arvid Norberg
675d16a2c3
remove remainder of eviction/ghost torrent feature ( #1251 )
...
remove remainder of eviction/ghost torrent feature
2016-10-25 08:02:34 -04:00
Steven Siloti
cf7db392b6
assert that offset didn't change while hashing
2016-10-25 07:59:02 -04:00
Steven Siloti
f36b9a805a
avoid concurrent access to hash offset
...
Since partial_hash::offset is not an atomic it is technically UD to access it
concurrently from multiple threads.
2016-10-25 07:59:02 -04:00
Steven Siloti
241e9fd25a
add assert to detect index out-of-range
2016-10-25 07:59:02 -04:00
Alden Torres
8bdbaec872
minor cleanup refactor ( #1252 )
2016-10-24 20:19:01 -04:00
Arvid Norberg
f16d0b7953
add unit test for 'file_sizes' entry in resume data ( #1248 )
...
add unit test for 'file_sizes' entry in resume data. fix resume data bug in client_test for magnet links and minor resume data cleanup in default_storage
2016-10-23 22:01:09 -04:00
Arvid Norberg
5341be1e84
more improvement to error/exception handling ( #1247 )
...
improvement to error/exception handling
2016-10-22 22:00:47 -04:00
Steven Siloti
a6e5ba8804
return a span from TORRENT_ALLOCA ( #1244 )
...
return a span from TORRENT_ALLOCA
Unfortunately this requires moving the variable declaration inside the macro.
Due to alloca’s unique properties pretty much the only safe way to call it is
in a simple assign-to-pointer expression. Therefor we need to use a temporary
pointer to store the value returned from alloca before we can call span’s ctor.
This also causes double evaluation of the size parameter which is unfortunate,
but no current callers of TORRENT_ALLOCA have a problem with this. Passing
expressions with side effects to macros is bad mojo anyways.
2016-10-22 14:43:40 -04:00
Pavel Pimenov
e9f9c3ca22
Fix sizeof(values)/sizeof(values[0] ( #1246 )
2016-10-22 14:12:23 -04:00
Arvid Norberg
6148984426
remove whitespace at end of line ( #1245 )
2016-10-22 11:47:24 -04:00
arvidn
31d34fec41
fix issue in previous block_cache patch
2016-10-22 11:08:19 -04:00
Arvid Norberg
2d2874d252
minor block_cache cleanup. make hash be a unique_ptr ( #1241 )
2016-10-21 07:37:15 -04:00
Alden Torres
a12f62593e
minor code refactor in disk_io_thread and block_cache ( #1238 )
2016-10-21 00:25:48 -04:00
Pavel Pimenov
8c20f4e1fd
utp_match: Reduced call boost::asio::ip::address address() ( #1235 )
...
check connection ID before source address in uTP connection lookup
2016-10-20 20:49:59 -04:00
Alden Torres
ad6af13129
deleted mpi.cpp from merge of RC_1_1 ( #1236 )
2016-10-20 16:16:42 -04:00
arvidn
b1e22e6183
merged RC_1_1 into master
2016-10-20 00:36:54 -04:00
Arvid Norberg
5012fcf10b
fix bug in last-seen-complete ( #1234 )
2016-10-20 00:15:26 -04:00
Alden Torres
fe754453f4
backport of fix for LFS support in android ( #1232 )
2016-10-20 00:14:03 -04:00
Arvid Norberg
7009001f73
fix ambiguous call to abs() in tommath ( #1228 )
...
fix ambiguous call to abs() in tommath
2016-10-20 00:13:45 -04:00
Pavel Pimenov
037f349cee
Try resolve #1175 (for RC_1_1) ( #1230 )
...
https://github.com/arvidn/libtorrent/pull/1223
2016-10-19 17:29:35 -04:00
Pavel Pimenov
91845aa6c8
Prevent duplicate url ( #1231 )
...
prevent creating torrents with duplicate trackers as well as adding duplicate trackers to torrent_info
2016-10-19 17:28:35 -04:00
Alden Torres
5f04103a9d
ensure posix calls with LFS support are used in android ( #1226 )
2016-10-19 13:00:03 -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
Arvid Norberg
524f7b1c27
fix error handling by exercising code paths where memory allocations fail ( #1221 )
...
fix error handling by exercising code paths where memory allocations fail
2016-10-19 01:18:05 -04:00
Arvid Norberg
85fe06659e
fix buffer overrun in dht_get_peers_reply_alert ( #1219 )
2016-10-16 19:40:39 -04:00
Alden Torres
0f20af3710
minor refactor, consts and cleanup in alerts ( #1210 )
...
minor refactor, consts and cleanup in alerts
2016-10-16 03:12:41 -04:00
Steven Siloti
fc7b4c1c4f
update comment to reflect new quota definition
2016-10-15 21:32:14 -04:00
Steven Siloti
c13286b945
take upload speed into account in round-robin choker
...
The unchoked peers need to be sorted by upload speed so that the slowest node
will get choked as part of optimistic unchoking.
Also change the minimum quanta to 1 minute instead of 256KB.
Also remove a useless multiply in the fastest peer choker since the priorities
are guarenteed to be equal at that point.
Fixes #1171
2016-10-15 21:32:14 -04:00
Arvid Norberg
c4119158a4
use in-class initializers for torrent_status ( #1215 )
2016-10-15 17:35:50 -04:00
Arvid Norberg
c18c12a144
remove ghost torrent/torrent eviction feature. ( #1214 )
...
remove ghost torrent/torrent eviction feature. It was very complex and did not solve the problem very well
2016-10-15 13:32:59 -04:00
Arvid Norberg
25195a7260
back port DHT fixes from master ( #1209 )
...
back port DHT fixes from master
2016-10-14 23:47:59 -04:00
Angel Leon
9cdf0ee50c
Boolean simplifications (oct 13th 2016) ( #1211 )
...
boolean simplifications
2016-10-14 16:13:18 -04:00
Alden Torres
8839722bec
minor http related code cleanup ( #1212 )
2016-10-14 16:12:02 -04:00
Arvid Norberg
540b5b28d7
use signed counters in traversa_algorithm, and add some more asserts ( #1208 )
...
use signed counters in traversal_algorithm, and add some more asserts
2016-10-14 08:03:09 -04:00
Arvid Norberg
e0c8ad738d
include target in DHT lookups, when queried from the session ( #1207 )
2016-10-12 23:39:00 -04:00
Alden Torres
e0d7729f87
using arm neon inline assembly and using it only if in 32 bits ( #1201 )
...
using arm neon inline assembly
2016-10-12 00:02:02 -04:00
Arvid Norberg
c966435d1c
fix issue where shutting down the session immediately and asynchronously starting the DHT would cause a shutdown hang ( #1203 )
2016-10-10 22:54:19 -04:00
Arvid Norberg
6bb2d7c017
Sanitize 1.1 ( #1197 )
...
enable address sanitizer
2016-10-09 17:00:20 -04:00
arvidn
57704d0249
Merge branch 'master' of https://github.com/arvidn/libtorrent
2016-10-08 14:18:12 -04:00
arvidn
1c89fcda48
merge RC_1_1 into master
2016-10-08 14:17:51 -04:00
Arvid Norberg
20f65946f2
make single-argument constructors explicit ( #1194 )
...
make single-argument constructors explicit
2016-10-08 14:07:11 -04:00
Arvid Norberg
5f7e2eb928
run undefined sanitier on travis/linux ( #1134 )
...
run undefined sanitizer on travis/linux. back-port ed25519 unit test from master
2016-10-08 12:29:46 -04:00
Arvid Norberg
7bfb97ba44
use in-class default initializers for utp_stream class members ( #1196 )
...
use in-class default initializers for utp_stream class members
2016-10-08 12:12:33 -04:00
Alden Torres
f580fcaa67
refactor in buffer.hpp to not use anonymous namespace in header ( #1192 )
...
refactor in buffer.hpp to not use anonymous namespace in header
2016-10-08 01:12:34 -04:00
Pavel Pimenov
93d8955750
Fix #1182 ( #1188 )
...
Add webseed URL duplicate check
2016-10-07 15:36:40 -04:00
Pavel Pimenov
af2a9a875b
Fix sizeof(X)/sizeof(T) and _countof ( #1189 )
...
https://msdn.microsoft.com/en-us/library/ms175773.aspx
http://www.viva64.com/en/w/V651/print/
2016-10-06 17:45:35 -04:00
Arvid Norberg
5c361715da
handle exceptions in session and torrent io_service jobs ( #1185 )
...
handle exceptions in session and torrent io_service jobs
2016-10-06 00:08:14 -04:00
Arvid Norberg
3c355bb3f8
use string_view in alert constructors ( #1186 )
2016-10-04 23:58:26 -04:00
Alden Torres
9343f2fbfb
minor header cleanup and refactor ( #1179 )
2016-10-04 07:43:34 -07:00
Alden Torres
be70afa4b8
refactor log methods in public peer_connection_handle for stable ABI ( #1180 )
...
expose log functions in peer_connection_handle with empty bodies when logging is disabled
2016-10-03 21:35:40 -07:00
Arvid Norberg
7a52a285a1
back-port error_code cleanup from master ( #1173 )
...
back-port error_code cleanup from master
2016-10-03 16:32:40 -07:00
Arvid Norberg
8bb7aa62ae
generalize and improve http redirect support for web seeds ( #1060 )
...
generalize and improve http redirect support for web seeds
2016-10-02 23:08:03 -07:00
Arvid Norberg
cebd976cc2
fix error_code vs. error_condition traits ( #1169 )
...
fix error_code vs. error_condition traits. deprecate get_*_category(), instead use *_category()
2016-10-02 12:27:50 -07:00
Alden Torres
1974dca150
minor refactor of dht_default_storage ( #1166 )
...
refactor of dht_default_storage structures
2016-09-30 20:42:57 -04:00
Alden Torres
331a8d53c0
refactor to use move with dht_state ( #1163 )
...
refactor to use move with dht_state
2016-09-29 08:25:51 -04:00
Alden Torres
af92e91a90
missing inc dht counter and minor cleanup ( #1164 )
2016-09-28 23:25:08 -04:00
Alden Torres
84e735c0ea
refactor for more use of move with settings_pack ( #1162 )
2016-09-28 13:28:43 -04:00
Steven Siloti
85dd682551
fix adding a node with unknown id ( #1161 )
...
Commit a414e4c3
broke adding nodes with unknown id to the routing table by
causing them to be evicted when they responded with their real id. This should
have been caught by test_bootstrap, but a typo caused that test to silently
exit early.
2016-09-28 13:28:21 -04:00
Alden Torres
8caebbd026
alerts refactor to use span, don't break ABI when logging, fix compilation ( #1159 )
...
alerts to use span, don't break ABI when logging, fix compilation
2016-09-27 23:21:18 -04:00
Arvid Norberg
f592d7fcb0
various cleanup and formatting updates ( #1158 )
2016-09-26 20:05:04 -04:00
Alden Torres
31ce1e5a2c
dht headers and minor cleanup ( #1157 )
2016-09-26 18:04:42 -04:00
Arvid Norberg
9cebd4569f
general cleanup of disk_buffer_holder and tailqueue ( #1156 )
...
general cleanup of disk_buffer_holder and tailqueue
2016-09-26 14:22:38 -04:00
Arvid Norberg
179e238561
move bitfield's find_first_set and find_last_clear into cpp file ( #1155 )
2016-09-26 10:58:09 -04:00
Arvid Norberg
97c6a75084
add proper error handling to peer connections and session ( #1149 )
...
add proper error handling to peer connections and session. i.e. catch exceptions in asio handlers and catch by const reference
2016-09-25 09:50:48 -04:00
Alden Torres
b60fe066e2
compare with generic_category in close_reason ( #1152 )
2016-09-25 01:42:45 -04:00
Alden Torres
4693fcf3f1
dht source code and headers cleanup ( #1150 )
2016-09-24 22:20:20 -04:00
Arvid Norberg
da8af033cc
modernize utf8 conversion functions to throw and move ( #1145 )
...
modernize utf8 conversion functions to throw and move
2016-09-24 22:16:10 -04:00
Arvid Norberg
372d992d8e
make connection_type enum an enum class ( #1146 )
2016-09-24 10:47:17 -07:00
Arvid Norberg
d2002c5248
separate piece_block and has_block out to their own headers ( #1148 )
2016-09-24 08:46:56 -07:00
Arvid Norberg
48a647a169
String view entry ( #1147 )
...
make entry support string_view in its interface, and make it efficient when in in C++14
2016-09-24 06:10:54 -07:00
Steven Siloti
2e0140b6f6
fix peer picking algorithm ( #1141 )
...
fix peer picking algorithm. The old code was always picking the first to_pick peers from the set.
2016-09-24 06:08:52 -07:00
Alden Torres
b1b74657f6
added consts and minor refactor ( #1137 )
...
added consts and minor refactor
2016-09-23 13:51:20 -07:00
Alden Torres
158ae3a4ba
consts, minor refactor, typos and test ( #1142 )
2016-09-23 13:49:39 -07:00
Arvid Norberg
24b271b7c1
Merge pull request #1133 from ssiloti/peer-picker
...
fix DHT peer picking algorithm. The old code was always picking the first to_pick peers from the set.
* use a sorted vector to store peer announcments
Given the frequency of linear scans being done, std::set is clearly
sub-optimal for storing announced peers. A std::vector is the obvious
choice, which I also decided to make sorted. A sorted vector trades
better performance in announce_peer for slower purging, the latter
being mitigated by batching.
* shrink peers vectors with too much excess capacity
2016-09-23 13:48:00 -07:00
Steven Siloti
35cfc6b5d3
shrink peers vectors with too much excess capacity
2016-09-23 07:30:36 -07:00
Steven Siloti
89942bf3d4
use a sorted vector to store peer announcments
...
Given the frequency of linear scans being done, std::set is clearly
sub-optimal for storing announced peers. A std::vector is the obvious
choice, which I also decided to make sorted. A sorted vector trades
better performance in announce_peer for slower purging, the latter
being mitigated by batching.
2016-09-22 21:54:10 -07:00
arvidn
70199041f7
merged RC_1_1 into master
2016-09-22 13:48:12 -07:00
Arvid Norberg
885e4f8fc4
use default member initializers instead of initialization lists in announce_entry ( #1129 )
2016-09-22 12:00:31 -07:00
Alden Torres
c7ec987a1b
refactor in msg verify_message and minor cleanup ( #1131 )
2016-09-21 23:04:05 -07:00
Steven Siloti
23e11af899
fix peer picking algorithm
...
The old code was always picking the first to_pick peers from the set.
2016-09-21 20:21:34 -07:00
Steven Siloti
c75b243490
remove redundant protocol parameter ( #1128 )
2016-09-21 20:00:39 -07:00
Arvid Norberg
269e384c2c
use string_view in create_torrent ( #1120 )
...
use string_view in create_torrent
2016-09-21 19:59:43 -07:00
Arvid Norberg
b20b3ad1ac
remove file size limit in torrent_info filename constructor ( #1126 )
2016-09-21 19:54:42 -07:00
Arvid Norberg
f712caa80d
deprecate send_stats property on trackers (since lt_tracker extension has been removed) ( #1125 )
2016-09-21 16:54:49 -07:00
Pavel Pimenov
62536c790d
Decreased performance. Ineffective use of the 'count' function. It can possibly be replaced by the call to the 'find' function ( #1127 )
2016-09-21 16:51:51 -07:00
Arvid Norberg
770b0def0c
Merge pull request #1122 from ssiloti/peers-storage-policy
...
new peers storage policy
2016-09-21 07:35:34 -07:00
Arvid Norberg
03068ffa0b
Merge pull request #1108 from arvidn/user-agent-1.1
...
user agent anonymous mode
2016-09-21 07:25:15 -07:00
Arvid Norberg
752ff24357
Merge pull request #1123 from aldenml/system-port-and-logs-1.2
...
* accept port 0 in listen_interfaces
* more session log and source code refactor
2016-09-20 23:50:49 -07:00
Arvid Norberg
3e7e806a77
deprecate old session_settings API (use settings_pack instead) ( #1117 )
...
deprecate old session_settings API (use settings_pack instead)
2016-09-20 23:49:23 -07:00
Alden Torres
f139776542
using consts refs in add_torrent_alert ( #1124 )
2016-09-20 23:14:42 -07:00
Arvid Norberg
4d716361c0
minor code cleanup ( #1116 )
2016-09-20 22:10:06 -07:00
Alden Torres
35f98f6a4d
added a few consts to file_storage and typos ( #1111 )
2016-09-20 22:06:07 -07:00
Steven Siloti
dad0000015
send write token if peer is alraedy stored
2016-09-20 19:35:24 -07:00
Alden Torres
4f6ea4a70d
more session log and source code refactor
2016-09-20 11:24:24 -04:00
Alden Torres
089d6c3144
accept port 0 in listen_interfaces
2016-09-20 11:11:24 -04:00
Steven Siloti
e2fefb074a
always drop the announcing peer when at capacity
2016-09-19 21:51:10 -07:00
Steven Siloti
6e24bbe77a
only send a write token if we have storage space available
2016-09-19 21:51:10 -07:00
arvidn
85a2a5c5cb
don't send user-agent in metadata http downloads or UPnP requests when in anonymous mode
2016-09-18 17:16:03 -07:00
Arvid Norberg
acf77a5385
fix tail-padding for last file in create_torrent ( #1106 )
2016-09-18 20:08:27 -04:00
Alden Torres
db14df5d0d
dht code related refactor and cleanup ( #1107 )
...
dht code related refactor and cleanup
2016-09-18 20:08:15 -04:00
Arvid Norberg
80ba45e1fb
clean up read_endpoint_list ( #1102 )
2016-09-18 10:12:54 -04:00
Arvid Norberg
219b2c36b4
upnp and natpmp modernization and cleanup ( #1103 )
...
upnp and natpmp modernization and cleanup
2016-09-18 10:11:56 -04:00
Arvid Norberg
527772420a
fix tail padding in file_storage::optimize and improve file placement with some tests ( #1105 )
2016-09-18 00:24: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
b4da884f29
created lsd_callback, log optimization and cleanup in lsd ( #1099 )
2016-09-16 12:21:41 -04:00
Alden Torres
d94c317f02
created portmap_callback and refactor for natpmp and upnp log optimization ( #1096 )
...
created portmap_callback and refactor for natpmp and upnp log optimization
2016-09-16 09:53:17 -04:00
Alden Torres
d9489878a0
rpc_manager log optimization and minor refactor ( #1095 )
...
more on log optimization
2016-09-16 08:21:07 -04:00
Alden Torres
0507764d04
consts and refactor, hash_address returns the hash ( #1093 )
...
consts and refactor
2016-09-15 21:13:43 -04:00
Steven Siloti
0759b732c1
web_peer_connection: make a copy of the request before calling incomi… ( #1091 )
...
web_peer_connection: make a copy of the request before calling incoming_piece
2016-09-14 12:29:07 -04:00
Steven Siloti
3d3367387a
check the address family of peers in get_peers ( #1090 )
2016-09-14 11:29:27 -04:00
Alden Torres
c25bae163d
avoid warnings with clang and minor dht_tracker code changes ( #1092 )
2016-09-14 11:28:50 -04:00
Alden Torres
acf353e26a
general session, torrent and peer connection log optimization ( #1088 )
...
general session, torrent and peer connection log optimization
2016-09-13 22:46:07 -04:00
Arvid Norberg
392726a2a9
factor out code from alert_manager::should_post template into non-template ( #1089 )
2016-09-13 22:45:39 -04:00
Alden Torres
224ebc1ded
peer_connection log related optimization ( #1086 )
...
peer_connection log related optimization and making m_alert_mask atomic
2016-09-13 17:07:22 -04:00
sledgehammer999
22043fd186
Use std::random instead of Boost.Random when in c++11 mode. ( #1087 )
2016-09-13 17:07:01 -04:00
Alden Torres
65cdc15543
more on log, consts, refs and cleanup in dht related code ( #1082 )
...
more on log, consts, refs and cleanup in dht related code. moving print_state out of main source code
2016-09-13 08:18:47 -04:00
Steven Siloti
850eca1f21
don't pop request until we're done with it ( #1085 )
2016-09-13 02:37:00 -04:00
milesdong
dc4d9af2e6
fix invalid memory access in utp_stream and torrent ( #1084 )
...
fix invalid memory access in uTP PMTUd
2016-09-13 02:36:23 -04:00
Alden Torres
3fa74c6fd5
more consts refs and formatting ( #1080 )
2016-09-12 09:20:15 -04:00
arvidn
fbf926da1f
Merge branch 'master' of https://github.com/arvidn/libtorrent
2016-09-11 21:02:35 -04:00
arvidn
33414de68d
merged RC_1_1 into master
2016-09-11 21:01:03 -04:00
Alden Torres
1a0c6f5e61
more dht log optimizations ( #1079 )
2016-09-11 20:49:15 -04:00
Alden Torres
4d4eb66c8b
some refactor, more const refs and span use ( #1078 )
...
some refactor, more const refs and span use
2016-09-11 01:58:48 -04:00
Alden Torres
5480e2eedc
some consts refs and refactor ( #1075 )
...
some consts refs and refactor
2016-09-09 15:02:20 -04:00
Alden Torres
99da5c8017
dht log optimization, consts and refactor ( #1073 )
...
dht log optimization and refactor
2016-09-08 19:13:46 -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
4c53d7b2da
refactor to use std unordered containers and minor cleanup ( #1070 )
2016-09-06 23:37:36 -04:00
Alden Torres
5e69dc700c
minor cleanup and refactor ( #1069 )
2016-09-06 18:34:03 -04:00
Alden Torres
e4a27c0b4b
backport of fix in resolve_links::match ( #1068 )
...
backport of fix in resolve_links::match
2016-09-06 18:30:30 -04:00
Alden Torres
7a0da72813
use of std::unordered_multimap and fix in resolve_links::match ( #1067 )
...
use of std::unordered_multimap and fix in resolve_links::match
2016-09-06 13:04:28 -04:00
Alden Torres
b313de3925
some refactor and cleanup ( #1065 )
2016-09-05 22:25:20 -04:00
Arvid Norberg
994a84cfe8
enable string tests on appveyor ( #1064 )
2016-09-05 15:17:12 -04:00
Alden Torres
0d64bda8d3
refactor to use unique_ptr with session_impl::m_work ( #1063 )
2016-09-04 21:49:11 -04:00
Alden Torres
e11f233086
minor cleanup/refactor ( #1062 )
2016-09-04 18:24:20 -04:00
Alden Torres
728e74eca7
refactor to avoid use of optional with piece_block_progress ( #1061 )
2016-09-04 12:31:02 -04:00
Alden Torres
29a4075555
refactor to use std::shared_ptr with dht observer ( #1057 )
...
refactor to use std::shared_ptr with dht observer
2016-09-02 21:05:11 -04:00
Alden Torres
fd4c09d7b2
refactor to use std::shared_ptr with traversal_algorithm ( #1056 )
...
refactor to use std::shared_ptr with traversal_algorithm. use a more stable linaro gcc link
2016-09-02 16:42:55 -04:00
Arvid Norberg
19dd9d323a
add some const and enum class ( #1055 )
2016-09-02 08:27:38 -04:00
Alden Torres
585a760588
headers cleanup ( #1054 )
...
headers cleanup
2016-09-01 15:04:58 -04:00
Alden Torres
3faa771843
removed use of boost::bind and boost::scoped_array ( #1053 )
2016-09-01 09:43:53 -04:00
Arvid Norberg
5f5589d137
deprecate and remove remote_dl_rate feature ( #1051 )
...
deprecate and remove remote_dl_rate feature
2016-09-01 09:43:08 -04:00
Arvid Norberg
c310d15cac
deprecate some settings that aren't in use anymore ( #1052 )
2016-09-01 09:42:49 -04:00
Steven Siloti
29e6cbbdae
fix exit condition when parsing nodes ( #1046 )
...
fix exit condition when parsing nodes
2016-09-01 00:49:21 -04:00
Alden Torres
bf0008933a
refactor to use std::shared_ptr with peer_connection, core and tests ( #1050 )
2016-08-31 21:42:18 -04:00
Alden Torres
6e891a0211
refactor to use std::shared_ptr with http_connection ( #1049 )
2016-08-31 12:45:45 -04:00
Alden Torres
cdb15ba886
refactor to use std::shared_ptr with torrent ( #1048 )
2016-08-31 08:27:36 -04:00
Arvid Norberg
44a761e5c8
Merge pull request #1047 from ssiloti/rpcm-cleanup
...
rpc_manager: remove unused timer
2016-08-31 02:04:00 -04:00
Steven Siloti
134d62ab08
rpc_manager: remove unused timer
2016-08-30 19:40:11 -07:00
Alden Torres
658fa46f0a
no warnings in random with openssl-1.1 and minor refactor
2016-08-30 21:23:08 -04:00
Arvid Norberg
33ec20f7b6
more use of std::shared_ptr refactor ( #1043 )
2016-08-30 21:16:34 -04:00
arvidn
b554909486
hint DHT bootstrap nodes of actual bootstrap request
2016-08-30 21:15:35 -04:00
Alden Torres
cfd2caeb74
no more extension_list_t type and uncommented call to torrent_plugin::on_load ( #1042 )
2016-08-30 17:36:44 -04:00
Alden Torres
e2487c4d24
more use of std::shared_ptr refactor
2016-08-30 10:10:53 -04:00
Arvid Norberg
88fe6ae8c3
don't link against sha1.cpp when using libcrypto's implementation ( #1040 )
2016-08-30 08:25:07 -04:00
Alden Torres
2ac45d17ef
ed25519 api refactor ( #1041 )
2016-08-30 02:37:51 -04:00
Alden Torres
ebe53883b5
refactor in escape_string and escape_path to use string_view ( #1039 )
2016-08-29 22:37:19 -04:00
Arvid Norberg
9ac7475a90
simplify some constructors with in-class initializers ( #1038 )
...
simplify peer_connection, torrent and session_impl's contstructors by moving simple parts to their header files
2016-08-29 20:29:27 -04:00
Alden Torres
32f5f8f257
better integration and API for ed25519 ( #1037 )
...
better integration and API for ed25519. using shared_ptr in ed25519_add_scalar
2016-08-29 20:28:42 -04:00
Alden Torres
118e30fd86
minor cleanup/refactor ( #1036 )
2016-08-28 00:04:16 -04:00
Arvid Norberg
c7eb76593c
deprecate torrent priority ( #1032 )
...
deprecate torrent priority
2016-08-26 12:37:23 -04:00
Alden Torres
227b630bd1
added string_ends_with to replace boost ( #1034 )
...
added string_ends_with to replace boost
2016-08-26 12:36:09 -04:00
Alden Torres
c05e29c48e
trivial cleanup and minor changes ( #1033 )
2016-08-26 00:14:11 -04:00
Steven Siloti
3a665a1040
fix inconsistant prefix calulcation ( #1030 )
...
The special case for calculating the prefix in the last bucket was being
applied to the condidate node but not the existing nodes in the bucket.
2016-08-25 19:26:48 -04:00
Alden Torres
44d9f456f8
adding support for a more configurable sha512 hasher ( #1028 )
...
adding support for a more configurable sha512 hasher, digest32 template, using hasher512.
2016-08-25 19:07:16 -04:00
Arvid Norberg
558ec097a2
fix applying settings to only take actual updates into account ( #1027 )
2016-08-22 21:38:57 -04:00
Alden Torres
73d6ba6ae3
using span in torrent_handle and no optional in torrent_info ( #1023 )
2016-08-22 11:02:51 -04:00
Arvid Norberg
2a36f9015d
build mpi.c as c++ to allow including boost headers ( #1026 )
...
build mpi.c as c++ to allow including boost headers
2016-08-22 07:59:46 -04:00
arvidn
97ce1b07bf
fix building tarball
2016-08-21 20:21:50 -04:00
Arvid Norberg
3f693fde42
fix build ( #1025 )
...
fix build
2016-08-21 20:20:46 -04:00
arvidn
74fc0fae9d
merged RC_1_1 into master
2016-08-21 16:28:49 -04:00
Arvid Norberg
debf3c6e36
update puff.c for gzip inflation ( #1022 )
...
update puff.c for gzip inflation
2016-08-21 14:43:44 -04:00
Alden Torres
00510d2b06
more use of span and std::shared_ptr ( #1018 )
...
more use of span and std::shared_ptr
2016-08-21 13:37:11 -04:00
Arvid Norberg
80e5ce9b32
add a default DHT bootstrap node when it's enabled on session startup ( #1008 )
...
make the dht bootstrap nodes part of settings_pack instead, to make it possible to set them on startup. and add default
2016-08-21 12:15:19 -04:00
Arvid Norberg
daa453ef3b
back-port windows stack trace function to 1.1 ( #1017 )
...
back port exception handling and stack trace printing from master -> RC_1_1
2016-08-21 01:07:02 -04:00
Alden Torres
4d96939b7b
minor cleanup and refactor ( #1016 )
...
minor cleanup and refactor
2016-08-20 19:46:55 -04:00
Alden Torres
bd557ca2b2
minor refactor to make it more swig friendly ( #1014 )
2016-08-20 11:29:31 -04:00
Arvid Norberg
b701fb252a
clear alert nofify function when calling abort on a session, to avoid touching a destructed session object ( #1015 )
2016-08-20 11:04:44 -04:00
Alden Torres
9fd83aaa10
more use of std::shared_ptr ( #1009 )
...
more std::shared_ptr transition
2016-08-18 17:08:40 -04:00
Alden Torres
5789b02e1b
storage_interface refactor to use span and references ( #1007 )
...
storage_interface refactor to use span and references
2016-08-18 11:57:50 -04:00
Alden Torres
bb388563b3
refactor to use torrent_info with std::shared_ptr ( #1006 )
2016-08-17 17:26:35 -04:00
Alden Torres
7cee486cf7
extensions refactor to use span and std::shared_ptr ( #1005 )
...
extensions refactor to use span. use std::shared_ptr instead of boost::shared_ptr.
2016-08-17 14:30:24 -04:00
Alden Torres
f4127ae12b
refactor in crypto_plugin::decrypt to use tuple
2016-08-16 10:21:17 -04:00
Alden Torres
7a2b21407c
refactor in crypto_plugin to use span
2016-08-15 23:09:30 -04:00
Alden Torres
9b0bc2ed5f
peer_plugin refactor ( #1002 )
...
refactor of ut_pex peer storage
2016-08-15 21:05:39 -04:00
Alden Torres
f51e782905
using string_view in node::incoming_request and plugin::on_dht_request ( #1001 )
...
use string_view in node::incoming_request. changed plugin::on_dht_request to use string_view
2016-08-15 16:17:13 -04:00
Alden Torres
2f7adfbb92
no more deprecated std::random_shuffle ( #999 )
...
replace deprecated std::random_shuffle. more aggressive random_shuffle in DHT simulation setup. use travis_retry.
2016-08-14 19:48:31 -04:00
Arvid Norberg
bc8c49dc15
make file_status return the vector instead of taking an out-parameter ( #1000 )
...
make file_status return the vector instead of taking an out-parameter
2016-08-14 13:11:59 -04:00
arvidn
e247473b86
bump version number
2016-08-13 07:12:23 -04:00
arvidn
8c8c3d5587
replace boost::function with std::function
2016-08-13 07:07:26 -04:00
Arvid Norberg
e36e5efaba
use boost::string_ref ( #996 )
...
use boost::string_ref/boost::string_view in various parts of the code, in file_storage, some file functions and in bdecode.
2016-08-13 07:04:53 -04:00
Alden Torres
a966458f8c
minor cleanup ( #997 )
...
minor cleanup
2016-08-12 19:24:03 -04:00
Alden Torres
74c8054e8d
created session_params and refactor ( #993 )
...
created session_params and new session constructor
2016-08-11 20:32:14 -04:00
arvidn
231dffd392
fix whitespace
2016-08-08 18:16:05 -04:00
Arvid Norberg
8007b947fd
make pad-file and symlink support conform to BEP47 ( #992 )
...
make pad-file and symlink support conform to BEP47
2016-08-07 22:37:10 -04:00
arvidn
42b3fbe20a
merged RC_1_1 into master
2016-08-07 17:23:40 -04:00
Alden Torres
af565e2b86
added support for flz (find last zero) and copied bitfield functions from PR #565 ( #986 )
...
added support for flz (find last zero) and copied bitfield functions from PR #565
2016-08-07 16:21:08 -04:00
Arvid Norberg
e9a7271aca
add piece picker test for re-prioritizing downloading/writing/partial pieces ( #989 )
...
add piece picker test for re-prioritizing partial pieces and forward port steven's piece picker fix from RC_1_1
2016-08-07 16:05:20 -04:00
Steven Siloti
bc369683df
handle short reads when exporting a file ( #990 )
...
handle short reads when exporting a file. Pieces in the part file are not guaranteed to be fully written so short reads need to be handled rather than asserting.
2016-08-07 16:04:29 -04:00
Steven Siloti
d4296730d0
fix re-prioritizing a piece while it is downloading ( #987 )
...
update_piece_state does not expect that the piece's priority has also changed
since the last time the piece was updated. Make sure the piece's priority is
updated before trying to update the state.
2016-08-07 15:27:04 -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
7ea9e76b37
refactor for separation of clz software/hardware based ( #985 )
...
refactor for separation of clz software/hardware based
2016-08-05 15:51:37 -04:00
Arvid Norberg
1bae47479b
make settings_pack moveable ( #982 )
2016-08-05 00:28:03 -04:00
Alden Torres
fdfe69f414
fixed warnings and compilation issues ( #980 )
...
fixed warnings and compilation issues
2016-08-03 00:35:40 -04:00
Alden Torres
8fedfcdce6
more trivial cleanup ( #979 )
2016-08-02 17:58:15 -04:00
Alden Torres
3c9ed50d0b
some trivial cleanup ( #978 )
...
some trivial cleanup
2016-08-02 12:13:05 -04:00
Arvid Norberg
caa034b1ac
fix typo and add invariant check to piece_picker ( #977 )
...
fix typo and add invariant check to piece_picker
2016-08-02 07:20:13 -04:00
Arvid Norberg
5b230694e5
check autotools on travis ( #973 )
...
build and run tests with autotools on travis, and fix configure issues.
2016-08-02 00:46:15 -04:00
Alden Torres
0b3c64ee87
added TORRENT_EXPORT to avoid link weak symbol warning ( #975 )
2016-08-02 00:15:26 -04:00
Arvid Norberg
61031f1186
hack to allow timeout utp sockets that are about to be closed ( #976 )
2016-08-02 00:07:36 -04:00
Alden Torres
e55a310e79
use of BOOST_FALLTHROUGH, typos and minor cleanup
2016-08-01 11:42:18 -04:00
arvidn
24dd6d0945
fix warning
2016-07-31 10:02:54 -04:00
arvidn
192559f245
fix warnings of unused return values from ftruncate() calls
2016-07-31 03:19:31 -04:00
arvidn
0126f6f2c6
fix timestamp arithmetic overflow
2016-07-30 00:38:17 -04:00
arvidn
2bdeb9aa6b
fix build
2016-07-29 20:24:11 -04:00
arvidn
e5ecd73751
fix rebase
2016-07-29 18:47:05 -04:00
arvidn
83dba91168
use span for to_hex and from_hex functions
2016-07-29 18:42:18 -04:00
Arvid Norberg
1d514b3f99
Merge pull request #961 from ssiloti/dht-sanitizing
...
remove DHT nodes which change their id
2016-07-29 18:00:22 -04:00
Steven Siloti
0343bb382e
always check m_log before using it
2016-07-29 13:32:28 -07:00
Steven Siloti
44ce5c71e7
cleanup ip logging
2016-07-28 20:08:24 -07:00
Alden Torres
a88c733f92
mark encryption_handler with TORRENT_EXTRA_EXPORT and minor cleanup ( #963 )
2016-07-28 14:57:26 -04:00
Alden Torres
68b1fc2fe8
fixed span::fist logic and minor cleanup ( #960 )
2016-07-28 01:54:57 -04:00
Steven Siloti
6ebc61cef9
reject nodes with our id after checking for an existing entry
...
This allows us to evict nodes which start reporting our id as theirs.
2016-07-27 21:10:34 -07:00
Steven Siloti
9d75198f7f
re-ping nodes in a bucket when one changes id
2016-07-27 21:10:34 -07:00
Steven Siloti
a414e4c3fa
remove nodes which change their id
...
This is based on a suggestion from the8472 to prevent malicious nodes from
polluting the routing table.
https://github.com/the8472/mldht/blob/sanitizing-docs/docs/sanitizing-algorithms.rst
2016-07-27 21:10:33 -07:00
Alden Torres
98918d61f5
removed const_interval, mutable_buffer and const_buffer types ( #956 )
...
removed const_interval, mutable_buffer and const_buffer types
2016-07-27 22:31:08 -04:00
Arvid Norberg
634c2bce60
Span conversion ( #944 )
...
complete http_parser transition to use span. make xml_parse use span. remove buffer::interval. convert some of receive buffer management to use span<>
2016-07-26 02:15:31 -04:00