Commit Graph

482 Commits

Author SHA1 Message Date
Charles Kerr 65fe66c470 (trunk libT) fix bug which caused libtransmission to hold onto nonproductive peers for longer than it should've 2008-12-11 07:04:46 +00:00
Charles Kerr 718c1caa96 (trunk libT) #1565: give the peer requests a higher send priority. thanks to jusid for testing and sleuthing above & beyond the call of duty 2008-12-08 20:36:36 +00:00
Charles Kerr 81e636ad89 (libT) #1577: honor the peer's BEP 10 reqq key, if they provide it. 2008-12-08 20:23:10 +00:00
Charles Kerr 9e98dcd248 (libT) minor cleanup: using tr_bool, fixing up bad code indentation, using %zu on size_t instead of casting to int... 2008-12-05 22:56:19 +00:00
Charles Kerr eb90a55608 (libT) #1562: 1.40 sends unnecessary `cancel' messages when choked 2008-12-05 01:12:55 +00:00
Charles Kerr 81c9bc0371 (libt) #1554: EPROTO (in peer-msgs.c) not defined on Windows 2008-12-03 13:21:41 +00:00
Charles Kerr d4ee0d714a (libT) #1379: support "partial seeds" BEP 22 2008-12-02 19:46:51 +00:00
Charles Kerr 341b40f192 libT) fix another r7234 bug reported by John_Clay 2008-12-02 19:38:46 +00:00
Charles Kerr c414377c1a (libT) fix r7234 bug reported by John_Clay 2008-12-02 19:06:08 +00:00
Charles Kerr 9d39ed2540 (libT) misc cleanup 2008-12-02 18:24:26 +00:00
Charles Kerr f927ea5d63 (libT) #1549: support fast exensions' "reject" and "have all/none" messages 2008-12-02 17:10:54 +00:00
Charles Kerr 0d5fed6442 (libT) re-apply jhujhiti's IPv6 patch. This merges in my tr_port cleanup, so any new bugs are mine :/ 2008-12-02 03:41:58 +00:00
Mitchell Livingston c2b6fde6dd #1548 Peers rapidly connect and reconnect after removing fast support. 2008-12-02 00:37:10 +00:00
Charles Kerr 7fa9813955 (libT) #252: revert r7195 (jhujhiti's IPv6 test patch). It seems to be the culprit in a `thrashing' issue reported by Waldorf and m1b in irc -- the behavior appeared between r7183 and r7187 -- so this commit is to trigger off a nightly build w/o the patch to test with in irc. 2008-12-01 20:21:06 +00:00
Charles Kerr a588eaddc8 (libT) fix a small pex memory leak 2008-12-01 05:57:59 +00:00
Charles Kerr 37414ea274 (libT) fix memory leak introduced in r7186 2008-12-01 05:56:39 +00:00
Charles Kerr f4f908be92 (libT) #1542: SIGSEGV in tr_publisherPublish 2008-11-30 21:36:49 +00:00
Charles Kerr a2ad4f6543 (libT) patch from jhujhiti to add ipv6 support. 2008-11-30 00:47:18 +00:00
Charles Kerr 40b5fc5351 (libT) #1532: patch from jhujhiti to remove (unused) fast extensions 2008-11-29 20:37:34 +00:00
Charles Kerr 7fee78a697 (libT) re-enable lazy bitfields 2008-11-29 19:16:31 +00:00
Charles Kerr d12af295c1 use tr_bool instead of C bitfields. (http://blogs.msdn.com/oldnewthing/archive/2008/11/26/9143050.aspx) 2008-11-28 22:11:41 +00:00
Charles Kerr ca433d44ae (libT) make peer-io's output buffer size more flexible based on the peer's speed 2008-11-28 16:00:29 +00:00
Charles Kerr b46375fd8c (libT) #1527: don't send pex messages if we don't have any new information to send 2008-11-28 05:48:17 +00:00
Charles Kerr f44248a7d7 (libT) yet another stab at getting bandwidth management under control. this version may suck less than previous attempts. It also breaks the mac build until someone adds iobuf.[ch] to xcode... 2008-11-25 21:35:17 +00:00
Charles Kerr be5e6774ad (libT) #1468: another stab at getting the peer transfer speeds both fast and a little more consistent. 2008-11-24 04:21:23 +00:00
Charles Kerr 0bcff74d52 minor code cleanup 2008-11-23 16:30:09 +00:00
Charles Kerr f172e8f96e (libT) another possible fix for #1468: Speed display is very jumpy 2008-11-20 03:07:26 +00:00
Charles Kerr a0fd42c5c3 (libT) better possible fix for #1468: Speed display is very jumpy 2008-11-17 04:00:57 +00:00
Charles Kerr 97e4efaa4d (libT) #1474: lazy bitfields don't work quite right in 1.40 2008-11-16 08:56:18 +00:00
Charles Kerr 58ea9e4be8 (libT) revise r7065 2008-11-07 05:37:59 +00:00
Charles Kerr c8b51fb734 #1429 (libT) cleaner handling of the special case where the upload or download speed limit is zero 2008-11-07 04:10:27 +00:00
Charles Kerr 8e4fa83c77 update NEWS 2008-11-06 02:56:51 +00:00
Charles Kerr a4bee061be (libT) eliminate some duplicate calls to time(NULL) that showed a spike on vraa & softwareelves' shark profiles 2008-10-27 04:12:42 +00:00
Charles Kerr e15114e2aa new & improved fix for #617: Transmission goes above the set bandwidth limits 2008-10-25 02:20:16 +00:00
Charles Kerr b04be5fb2e make MAX_PATH_LENGTH private to libtransmission. add tr_dirname() and tr_basename() utility / portability wrappers 2008-10-14 03:39:16 +00:00
Charles Kerr 88ce8a5c44 more changes inspired by spry's `winport' code: for portability, use the standard __VA_ARGS__ macro for variadic macros instead of the CPP extensions. 2008-10-13 22:45:05 +00:00
Charles Kerr f00c8ff34d possible fix for #1305 "Transmission losing data - Session Transfer significantly higher than actual download". This patch may need more user testing and will definitely make webseeds slower. suck it up. 2008-10-11 04:07:50 +00:00
Charles Kerr 7566be5348 #1302: Uploading file deletion is ignored 2008-10-10 03:04:46 +00:00
Charles Kerr 413211288b #1338: fix win32 build errors 2008-10-10 02:14:51 +00:00
Charles Kerr 964d7e193c (libT) #1338: EMSGSIZE and EPROTO not found on Windows 2008-10-10 00:38:37 +00:00
Charles Kerr 38d265d9f0 (libT) possible fix for #1305: Transmission losing data - Session Transfer significantly higher than actual download 2008-10-08 03:58:21 +00:00
Charles Kerr 4fab4c9e9b (libT) finish killing tr_errno. 2008-10-03 04:49:06 +00:00
Charles Kerr f9345da6ae (libT) eliminating tr_errno, part 2: don't use it in reqListPop() or reqListRemove() 2008-10-02 20:55:05 +00:00
Charles Kerr b1ef118e3f (libT) housekeeping: tr_torrent.handle --> tr_torrent.session 2008-10-02 15:53:33 +00:00
Charles Kerr cc89872dd4 run libT, cli, daemon, gtk through the source-code formatter "uncrustify" as promised/threatened 2008-09-23 19:11:04 +00:00
Charles Kerr 9c2c4ca08d fix at least one possible cause for the new crash reported by persept 2008-09-19 17:03:25 +00:00
Charles Kerr 4fe1e1dae3 first draft at having more accurate speed controls 2008-09-17 19:44:24 +00:00
Charles Kerr abd4b506e2 fix a confusing extraneous line in the previous commit 2008-08-27 18:56:36 +00:00
Charles Kerr 64e08510f0 (libT) maybe fix the hangs reported by users in the recent nightlies. 2008-08-27 18:50:21 +00:00
Mukund Sivaraman 75d2e74a64 Use stricter type for enums 2008-08-22 16:13:52 +00:00
Charles Kerr f8d38a180e according to vraa's profiling, the highest CPU hit other than encryption is in peerPulse(). do we really need to call it every 50 msec? change the peerPulse() interval to 250 msec. 2008-08-22 15:15:02 +00:00
Charles Kerr ef68e36a0d (libT) more dead code removal: tr_compareUint32(), tr_compareUint64(), tr_strcmp(), tr_strcasecmp() 2008-08-22 14:52:20 +00:00
Charles Kerr d323a99cdd undo part of r6616 to address the assertion failure reported by andersos and Waldorf 2008-08-22 01:27:00 +00:00
Charles Kerr 1105dc0038 (libT) remove some dead functions: tr_calloc(), tr_compareUint16(), tr_compareUint32() 2008-08-21 19:03:56 +00:00
Charles Kerr dcecf09d96 bencode cleanup: remove unused functions and unnecessary #includes 2008-08-21 14:57:59 +00:00
Charles Kerr 3b7499a79b make tr_bencDictFindType() private. 2008-08-20 18:42:45 +00:00
Mukund Sivaraman ed7685dd1a Make tr_bitfieldHas() a macro 2008-08-20 13:45:52 +00:00
Charles Kerr d06f101e57 #220: lazy bitfields 2008-08-16 21:06:57 +00:00
Charles Kerr 94ac86bec6 (libT) route all outbound peer protocol messages through the outMessages buffer, to ensure that they're sent in sequence. previously the outbound pex message wasn't queued in this way. 2008-08-16 05:11:28 +00:00
Charles Kerr d7ab0d8a15 possible quick-fix for the "wasted data due to collisions" bug reported in http://forum.transmissionbt.com/viewtopic.php?f=3&t=5643. surely it's not this easy, but let's see 2008-08-14 20:17:55 +00:00
Charles Kerr c75c512ff1 readability improvments #1, #2, #3, #4. (muks) 2008-08-12 13:51:11 +00:00
Charles Kerr 51aff87443 lots of C correctness tweaks suggested by sparse/cgcc 2008-08-11 19:05:02 +00:00
Charles Kerr 2e6443a53d #1168: reading past the end of KTorrent's pex added.f strings 2008-08-10 14:58:11 +00:00
Charles Kerr b860119cd3 minor text cleanup 2008-08-01 16:43:22 +00:00
Charles Kerr 96ae464283 rename `pulse' as peerPulse() and trackerPulse() to make backtraces easier to read 2008-07-28 19:47:16 +00:00
Charles Kerr 72880446d8 (daemon) #1107: transmission-remote -t[n] -i should display webseeding info 2008-07-27 14:10:32 +00:00
Charles Kerr 43b99f425a (libT) fix minor PEX memory leak reported by valgrind 2008-07-18 19:50:38 +00:00
Charles Kerr fd06d85aee part 1 of Aloisius' performance patch 2008-06-27 02:42:44 +00:00
Charles Kerr dce24eb1f0 libT: first cut at implementing the internal peers' request queues as pieces rather than blocks, as discussed with erdgeist and denis, to avoid a couple of nasty CPU bottlenecks. 2008-06-09 22:53:45 +00:00
Charles Kerr e3e3bee8b5 #800 initial support for GetRight-style fetching of data through http and ftp servers specified in the .torrent's "url-list" tag 2008-06-07 21:26:41 +00:00
Charles Kerr 041561f232 minor refactoring of tr_bitfield to (a) simplify the tests and (b) make things easier to read 2008-06-07 01:44:54 +00:00
Charles Kerr 5141a65d45 experimental message batcher as discussed in http://forum.transmissionbt.com/viewtopic.php?p=24251#24251 2008-05-31 00:16:26 +00:00
Charles Kerr 70fcc56beb (libT) (1) shave a few bytes from tr_peer and tr_ratecontrol's footprints. (2) remove some dead code. 2008-05-26 12:14:35 +00:00
Charles Kerr 53d8574b11 * change tr_stat.activityDate's and tr_stat.startedDate's type to time_t, since that's how everyone uses them anyway
* add a little more documentation to tr_stat and tr_ctor in transmission.h
2008-05-23 20:04:41 +00:00
Charles Kerr d18fb68fbc sine we now have two public ports (peer and rpc), rename "publicPort" as "peerPort" 2008-05-23 16:18:58 +00:00
Charles Kerr 2c79888a93 RPC/IPC redesign 2008-05-18 16:44:30 +00:00
Charles Kerr be9427931a ipc: add session accessor/mutators.
transmission.h: make the session API more consistent.
2008-05-12 16:33:17 +00:00
Mitchell Livingston 85e66062eb remove unused variables 2008-05-05 04:17:52 +00:00
Charles Kerr c20b9a6df4 experimental speed tweaks:
(1) increase the per-peer read buffer to the size of a block message
(2) pulse the peers more often
(3) reduce the tracker delay on startup
2008-05-01 19:31:58 +00:00
Charles Kerr a443cc3289 add #include <limits.h> to pick up a definition of INT_MAX to make Hudson happy 2008-04-19 19:39:39 +00:00
Charles Kerr 3445817a80 peer-msgs: faster upload speeds in situations with few peers. this patch needs wider testing for side-effects wrt speed limits. 2008-04-19 19:37:05 +00:00
Charles Kerr 08b27749ba #890: be smarter about noticing seeds from tracker & pex 2008-04-19 15:07:59 +00:00
Charles Kerr ac921e0f82 #881: undo r5631 2008-04-18 00:02:04 +00:00
Charles Kerr ea9e0b260f (1) fix choke/unchoke error. (2) if a peer keeps trying to reconnect to us, hang up during the handshake. 2008-04-17 03:48:56 +00:00
Charles Kerr 62709b7ca2 #881: follow the transmission spec wrt extension handshake message timing 2008-04-17 02:11:29 +00:00
Charles Kerr 8a8b1fedb0 #870: follow PEX conventions agreed upon by Azureus and uTorrent 2008-04-12 23:01:40 +00:00
Charles Kerr fc091499cb translators shouldn't have to translate debug messages 2008-04-06 00:38:18 +00:00
Charles Kerr fd0e71c00a hack on IPC a bit because it's been too long since I broke it 2008-04-03 21:38:32 +00:00
Charles Kerr c63b548195 fix bug that caused very large torrents to crash Transmission 2008-03-22 18:10:59 +00:00
Charles Kerr e7316dbc34 yet more string massaging 2008-03-19 02:16:07 +00:00
Charles Kerr 4fa1da4ee8 #781: (1) fix overreporting corrupt data, and (2) fix bug added in r5172 that didn't handle sent request TTL correctly, causing too many dupliate block requests. 2008-03-18 17:46:29 +00:00
Charles Kerr 05c6938f5a changes to message logging: (1) bring back "Torrent hasn't responded yet", but only in the message log. (2) make PEX messages debug. (3) log a message when a torrent reaches completion. 2008-03-18 16:56:01 +00:00
Charles Kerr 59fdf5dcc8 #781: try to get a little further on this `too much corrupt' ticket by adding a more helpful log message when a downloaded piece fails its checksum test. 2008-03-18 01:39:06 +00:00
Charles Kerr 23f33e1bd1 "Got 0 peers from peer exchange" is a pretty useless message. :) 2008-03-17 02:45:09 +00:00
Charles Kerr 29f092197f #138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages#138: per-torrent messages 2008-03-13 03:53:18 +00:00
Charles Kerr bcff72c3ad string consistency. (gtk) move `announce url' from info tab to tracker tab. 2008-03-08 02:00:47 +00:00
Charles Kerr 5e3dcb5f6f #751: more digging to try to figure out where the problem is. 2008-03-06 13:24:44 +00:00
Charles Kerr d6a6c24e18 remove more unused code in the peer-msgs module 2008-03-04 21:09:26 +00:00
Charles Kerr 2c9fef40ef remove unused code in the peer-msgs module 2008-03-04 20:37:24 +00:00
Charles Kerr 84a8592d1d first cut at adding i18n hooks into libtransmission. 2008-03-04 02:02:25 +00:00
Charles Kerr 08d986759b fix r5189 typo pointed out by BentMyWookie 2008-03-04 00:55:20 +00:00
Charles Kerr 3000d67e7f #751: add some tracer bullets to help track down this error. 2008-03-03 21:51:45 +00:00
Charles Kerr 24e05bf3fb harden the bitfield handling to handle corrupt messages from peers. This is in response to Ryoujin's crash report in the forums (http://forum.transmissionbt.com/viewtopic.php?p=20414#20414) 2008-03-02 23:44:34 +00:00
Charles Kerr f1c3b160af remove `banned' field for per-piece-per-peer banning. this has been unused since the three-strikes rule went in place. 2008-03-01 14:32:35 +00:00
Charles Kerr 0788bc37ed minor cleanups to peer-msgs 2008-03-01 14:09:18 +00:00
Charles Kerr 3de06974e8 #727: Download speed setting also affects upload speed, peer informations in torrent inspector 2008-02-29 17:09:33 +00:00
Charles Kerr a7d087b60a use a custom struct for the peer's four request queues since John_Clay's shark report shows it taking up about 40% of the time in malloc/free. also, maybe this will help the "idle memory" numbers some. 2008-02-29 03:41:50 +00:00
Charles Kerr 8cc587a66f more housekeeping: benc_val_t --> tr_benc 2008-02-26 21:58:58 +00:00
Charles Kerr deaeb24cb5 cleanup #includes for errno & strerror 2008-02-19 04:16:04 +00:00
Charles Kerr c144470c70 make the code a little easier to read. make tr_ioFileTest()'s return value consistent with other inout funcs. 2008-02-15 18:25:42 +00:00
Charles Kerr 4f4f451c17 possible fix for http://forum.transmissionbt.com/viewtopic.php?t=3946 2008-02-14 21:48:49 +00:00
Charles Kerr 8d14a789cb #698: `have' gets too far ahead of `verified' 2008-02-10 04:03:19 +00:00
Charles Kerr 2085aec390 #613: fix handshake protocol error reported by brad- and tracked down w/Lacrocivious' help. 2008-01-26 03:43:49 +00:00
Charles Kerr d922389c9d #613: fix handshake error with libtorrent / mainline peers 2008-01-24 17:16:20 +00:00
Charles Kerr 3c6eeef439 fix a socket leak in peer-msgs 2008-01-19 03:30:45 +00:00
Charles Kerr de515ee339 if the torrent's download path doesn't exist, don't create it -- it's might be a removeable disk that got unplugged. 2008-01-18 19:13:32 +00:00
Charles Kerr e7163a5433 #593: 1.01 crash 2008-01-13 15:52:56 +00:00
Charles Kerr 3a6396a3cb mingw portability fixes 2008-01-10 18:52:46 +00:00
Charles Kerr 5d93bd2c93 a smaller buffer size seems, counterintuitively, to improve the overall transfer rate when speed limits are turned on, because it gives more peers a chance to be involved in xfer before we hit the limit. 2008-01-09 19:22:25 +00:00
Charles Kerr 591f7f8b10 * improve the unchoking algorithm.
* when deciding which peers to connect to, take peer's previous speeds into account
* longer delay interval before reconnecting to peers that didn't give us data
* added uTorrent-inspired "flags" column in tr_peer_stat and gtk's torrent details' "peer" tab
2008-01-09 17:33:43 +00:00
Charles Kerr 1e45d3e478 better lazy generation of "allowed set": wait until we get the {have-all|have-none|bitfield} from the peer so that we'll know if they qualify for an allowed set 2008-01-06 22:20:44 +00:00
Charles Kerr 35f73c097c lazy "allowed set" generation. add regression test for "allowed set" generation. 2008-01-06 21:56:30 +00:00
Charles Kerr 6c3eab0a92 #585: 1.00 could be sped up by elminating reconnect intervals for some peers 2008-01-05 18:17:56 +00:00
Charles Kerr 085235b10b remove some unused #include <ctype.h> directives 2008-01-03 20:17:01 +00:00
Charles Kerr ee2cffa196 #579: assertion failure in ~r4410 2008-01-03 03:45:10 +00:00
Charles Kerr c6d2e60f52 fix comment typo reported by BigBossman 2007-12-27 22:50:20 +00:00
Charles Kerr e870440025 add a per-block request TTL of 120 seconds 2007-12-25 17:22:51 +00:00
Charles Kerr 473907d891 a little housekeeping: move tr_torrent stuff into its own header 2007-12-25 05:37:32 +00:00
Charles Kerr 401cfbdb6b replace the per-torrent PEX setting with a global one, as per discussion with SoftwareElves and BentMyWookie 2007-12-24 05:03:40 +00:00
Charles Kerr 4ff5b472a8 raise the maximum connection limit a bit. 2007-12-15 16:36:43 +00:00
Charles Kerr 39d8c74fcd small tweak to play nice with old C compilers. Thanks to fizz for reporting & submitting a patch 2007-12-03 19:52:55 +00:00
Charles Kerr abef433926 improve upload speeds when the speed limits are uncapped. 2007-12-01 23:08:34 +00:00
Charles Kerr 1e4b3a0577 make the peer stats a little easier to understand 2007-11-27 21:39:41 +00:00
Charles Kerr e354b82452 disable SWIFT on private trackers, because they are typically ratio-based sites where you *want* to upload as much as possible to deadbeats 2007-11-26 04:05:12 +00:00
Charles Kerr 8caa113d4b fix LTEP PEX error reported by Adrian Ulrich in the BitTorrent mailing list 2007-11-22 06:48:08 +00:00
Charles Kerr 91e672d428 some progress on the overall statistics, though probably not visible to end users yet 2007-11-21 20:03:53 +00:00
Charles Kerr 9f9901b3fa tweak the peer limits a bit for faster uploading 2007-11-20 17:29:56 +00:00
Charles Kerr 9cec81b524 fix the crash reported by pea_, Gimp, and John_Clay [ref: http://pastebin.ca/784834] 2007-11-19 21:44:38 +00:00
Charles Kerr 3704854654 add more asserts up the call chain to find the source of pea_ and Gimp's bug 2007-11-19 04:51:06 +00:00
Charles Kerr a277382578 more download speed tweaks for situations where T is both uploading and downloading. 2007-11-18 04:24:17 +00:00
Charles Kerr e371009606 this should improve download speeds. test it! 2007-11-18 03:18:26 +00:00
Charles Kerr 9a81cd7637 reintroduce the "SWIFT" algorithm 2007-11-18 01:00:49 +00:00
Charles Kerr 37969406b2 Add "Status" column to tr_peer_stat. 2007-11-17 23:43:33 +00:00
Charles Kerr 54a2bb978b fix timeout error that caused us to drop connections prematurely 2007-11-17 17:49:30 +00:00
Charles Kerr ef3d0df0d9 try to tickle some more information out of John_Clay's bug report 2007-11-17 07:48:51 +00:00
Charles Kerr 77d58126f4 remove yet more dead code 2007-11-17 02:47:47 +00:00
Charles Kerr cc728b0470 progress on the "speed limits kill my transfer rate" bug. 2007-11-16 21:58:11 +00:00
Charles Kerr 0ac302b302 progress on the "speed limits kill my transfer rate" bug. 2007-11-16 20:40:03 +00:00
Charles Kerr 73680b6263 fix tr_peerMsgsAddRequest memory leak reported by tiennou 2007-11-16 15:45:26 +00:00
Charles Kerr 1ebaf597a4 fix trunk memory leak reported by tiennou 2007-11-16 15:33:57 +00:00
Charles Kerr c3dce15a9e if we haven't advertised that we support pex, then even if a peer sends us a pex message, don't send one back. 2007-11-16 04:42:51 +00:00
Charles Kerr 257eaee631 more of the same 2007-11-15 05:47:23 +00:00
Charles Kerr a9e5fff2e6 * fix the `req->length == (uint32_t)( ((block)==((msgs->torrent)->blockCount-1))' bug.
* there seems to be a pattern for peers that were (intentionally?) giving incomplete data to trigger the bug above.  when a peer does this, give them a strike on its three-strikes-and-you're-banned count
2007-11-13 05:36:43 +00:00
Charles Kerr 8516860fec fix a bug in tr_stat's availability numbers, reported by BentMyWookie 2007-11-11 16:33:04 +00:00
Charles Kerr c32f893038 commit tiennou's fast-peers-final patch from ticket 149 2007-11-10 16:06:00 +00:00
Charles Kerr ca03b62a58 * fix a bug that could corrupt peer connections, causing slower speeds and/or fewer connections
* add more assertions to smoke out any remaining BT protocol bugs
2007-11-10 04:56:27 +00:00
Charles Kerr fd430fde90 undoing the r3773-r3774 experiment. 2007-11-09 20:07:52 +00:00
Charles Kerr 67b719c2de on Darwin, use NSCParameterAssert() instead of assert(). 2007-11-09 19:50:40 +00:00
Charles Kerr 99ea26c1c9 * try to get peers to scale up to speed faster.
* remove unnecessary steps when receiving block data from peers.
2007-11-09 01:22:15 +00:00
Charles Kerr 39f9f14751 minor tweaks. 2007-11-08 21:25:17 +00:00
Charles Kerr 71f4efcbad update our #includes now that libevent has cleaned up event.h 2007-11-07 18:26:19 +00:00
Charles Kerr 60aab6c433 remove libtransmission code that duplicates functionality in libevent 2007-11-06 21:14:30 +00:00
Charles Kerr 0f92cb7f30 fix bug reported in the forums by "grabman" 2007-11-05 03:09:27 +00:00
Charles Kerr 3e0e462b10 finish cleaning up the code that was churned during the "corruption" fix. 2007-11-01 13:47:32 +00:00
Charles Kerr a6206b036c "corruption" fix part 2: lots of assertions, and try to complete pieces & ban bad peers sooner 2007-10-31 04:23:51 +00:00
Charles Kerr ab8ed6507d #412 - 0.90 "ignores" speed limits (deanr, berkut, SineOtter) 2007-10-28 15:20:24 +00:00
Charles Kerr 92ac49d9c4 compatability with older C copmilers (ticket #422, patch by fizz) 2007-10-27 21:29:41 +00:00
Charles Kerr b00ee3e568 Ticket #398 (peer-msgs.c:905: failed assertion `msglen == 0' in 0.90) 2007-10-27 15:45:03 +00:00
Charles Kerr 8c0e2434f5 fix OpenBSD build error. 2007-10-25 13:59:46 +00:00
Charles Kerr b704654275 dead code removal. 2007-10-22 23:27:47 +00:00
Charles Kerr a5946e396c tweak the logging a bit. 2007-10-22 18:52:36 +00:00
Charles Kerr e1fbd16941 fix some memory leaks reported by valgrind. 2007-10-22 14:15:16 +00:00
Charles Kerr 6527f4e12a dead code removal. 2007-10-20 15:17:36 +00:00
Charles Kerr 25fa56d294 * don't fire the "status changed" event if the status changes while a torrent's being started for the first time.
* cleaner setting of the DND flags in the gtk+ client.
* cpStatus cleanup.
2007-10-19 23:23:21 +00:00
Charles Kerr 911ff1cdd1 remove tr_peerMsgsSetChoke()'s return value, which was always ignored anyway 2007-10-17 18:23:59 +00:00
Charles Kerr 6eb7edf007 fix choke fibrillation bug in new connections 2007-10-15 16:01:42 +00:00
Charles Kerr 57eaa27970 Fix bug that could initiate pex in private torrents. 2007-10-14 17:21:24 +00:00
Charles Kerr d96ed80aa2 (1) fix a bug in torrent creation. (2) fix a bug in torrent paths on startup in gtk 2007-10-14 03:26:13 +00:00
Charles Kerr 4f33a8da42 Try sharing a DH so that we don't spend so many cpu cycles making new ones when we're working through the peers trying to find good ones. 2007-10-13 23:15:43 +00:00
Charles Kerr 9211c57ad2 merge in the parts of peerutils' peer pruning code that still make sense 2007-10-13 13:54:05 +00:00
Charles Kerr 89564dc3c2 fix the "swarm speed" bug reported by Gimp_ 2007-10-11 04:17:28 +00:00
Charles Kerr 3b2ef1054f 8 second timeout during handshake, 2.5 minute handshake afterwards 2007-10-11 03:54:33 +00:00
Charles Kerr e11999243e add more debugging messages to track down why we're disconnecting from some peers 2007-10-11 03:36:09 +00:00
Charles Kerr cbaf1b8faa commit more of tiennou's fastpeers patch 2007-10-10 16:39:12 +00:00
Charles Kerr 696800f369 * fix bug that sent a keepalive message too often 2007-10-10 03:03:09 +00:00
Charles Kerr e8d19c5b03 fix stupid bug from yesterday that made uploading difficult. 2007-10-09 05:51:20 +00:00
Charles Kerr e176a25922 * fix a bug with uploading encrypted pice data to another peer
* extra sanity tests when uploading data
2007-10-08 16:10:10 +00:00
Charles Kerr 1014e633ac * don't reuse http connections to trackers. I think this is what caused most of the `no response from tracker X' messages.
* extra safety checks to ensure the last `stopped' message to the tracker is sent on shutdown.
2007-10-07 16:07:19 +00:00
Charles Kerr c75f49bc26 * add a per-peer request queue to hold the next 10-15 seconds' worth of requests so that we always have more requests at hand when the current requests start to run low.
* increase the tracker `numwant' variable to grow our peer pool
* bugfixes in cancelling requests.
* make the debug log sexy and readable like uTorrent's ;)
2007-10-06 18:20:52 +00:00
Charles Kerr b6483cbf3f don't allow duplicate requests to the same peer, even during endgame. (alus) 2007-10-05 00:16:47 +00:00
Charles Kerr 5f2bd1d950 speed improvements... this is getting me 700 KiB/s (which is near to my speed cap) in the ubuntu torrent test 2007-10-03 19:00:51 +00:00
Charles Kerr 877e2bb86e some more peer tweaks 2007-10-03 18:19:51 +00:00
Charles Kerr a3d1a254d1 minor source code cleanup... 2007-10-03 16:42:43 +00:00
Charles Kerr 3d2e3cfdfb add pass subscription info into the peer-msgs constructor so that we can start getting information immediately 2007-10-03 04:04:34 +00:00
Charles Kerr 1f1605986c tear out some now-exterraneous code. 2007-10-02 20:55:14 +00:00
Charles Kerr 3dbaa7d673 make the peer manager a little greedier w.r.t. keeping connections alive. 2007-10-02 19:25:18 +00:00
Charles Kerr f237bf7047 * simplify the the choking intervals
* fix peer-mgr destructor bug
* send debugging messagese to TR_DEBUG_FD instead of the console
2007-10-02 14:35:02 +00:00
Charles Kerr 84ab0092fb some cleanup... remove some dead/obsolete code 2007-10-02 00:05:40 +00:00
Charles Kerr 75ff12faba don't log BT protocol messages in UL/DL speed -- only log piece data transfers. 2007-10-01 16:31:17 +00:00
Charles Kerr 6bef7def52 tweaks 2007-10-01 00:08:12 +00:00
Charles Kerr 7cc6771318 experimental better peer management. 2007-09-30 23:55:49 +00:00
Charles Kerr dad333ceec more work on the locks 2007-09-29 14:55:30 +00:00
Charles Kerr 04f6847004 take out the `thawing out' console messages 2007-09-29 00:47:33 +00:00
Charles Kerr 3f1d888354 improved uTorrent handshaking, after talking to #utorrent-dev about minutae... 2007-09-29 00:46:41 +00:00
Charles Kerr 79973a8a93 commit the next step of tiennou's fastpeers code. 2007-09-28 16:40:21 +00:00
Charles Kerr 198d2c256e fix John_Clay's tracker assertion failure. 2007-09-28 16:14:19 +00:00
Charles Kerr c28a94d04c fix a couple of memory corruption errors while trying to track down tiennou's report on peer-msgs.c:pulse() -> inout.c:163 assertion failure. 2007-09-28 14:27:56 +00:00
Charles Kerr 439c1f38c1 some experimental code. (1) try to improve throughput to peers. (2) add first draft of new tr_stat fields requested by BentMyWookie (3) raise the per-torrent peer limit to 100 to match LibTorrent's defaults 2007-09-27 03:03:38 +00:00
Charles Kerr d386617da2 only send a peer keepalive messages when we're not sending them anything else 2007-09-26 17:34:33 +00:00
Charles Kerr 773fa8f1f6 for every connected peer, send a keepalive message every 90 seconds 2007-09-26 15:14:37 +00:00
Charles Kerr 7ccab9de2c peer i/o cleanup 2007-09-26 14:42:03 +00:00
Charles Kerr ee6a0b8945 modify the tr_stat struct as hashed out by charles_ and BentMyWookie. sync gtk, ipc, and wx clients. 2007-09-26 01:55:04 +00:00
Charles Kerr 73522af17c fix peer-msgs.c assertion failure. (tbo) 2007-09-25 22:30:41 +00:00
Charles Kerr 5aecf680f0 when a peer tells us that it's switched listening ports, remember the new port for the next time we connect. 2007-09-25 17:44:50 +00:00
Charles Kerr 1d1a23508b * follow the BT spec more closely by disallowing peers to request blocks of more than 16KiB from us.
* don't register the choke and connection timers for torrents that aren't running.  It doesn't hurt anything but does waste a few cycles.
2007-09-25 00:04:29 +00:00
Charles Kerr 6c8d9d42d3 fixed tracker bug reported by TooMuchTime of OiNK fame 2007-09-24 20:27:20 +00:00
Charles Kerr dd6f87a5eb fix race condition in the torrent rechecker. 2007-09-24 17:47:15 +00:00
Charles Kerr 6897fe4327 plug some minor memory leaks. (valgrind) 2007-09-24 15:50:59 +00:00
Charles Kerr b402687c93 * add sanity checks to incoming piece data requests. This may solve the inout.c:99 assertion failure.
* rename the gtk client from `transmission-gtk' to `transmission' for parity with the mac client.
2007-09-23 23:38:39 +00:00
Charles Kerr d27c9c5034 * update tor->activityDate whenever piece data is transferred. 2007-09-23 14:12:17 +00:00
Charles Kerr 968868debe fix bug that tended to disconnect from valid peers when we were seeding. also, follow the BT spec's terminology a little closer. 2007-09-23 02:19:59 +00:00
Charles Kerr 7a54e88d4e fix bug #342 -- some hash checks were incorrectly failing, which caused the `bytes downloaded' field to appear to jump back and forth 2007-09-23 02:11:53 +00:00
Charles Kerr 10b8326f1d add a peer connection manager s.t. have a consistent way of disconnecting from bad peers, connecting to new potential peers, disconnecting from seeds when we're seeding, etc. 2007-09-22 14:18:52 +00:00
Charles Kerr c6aa57f306 make download speed limits work? 2007-09-22 05:16:32 +00:00
Charles Kerr 87f53cba5b maybe get speed limits working. 2007-09-22 04:44:50 +00:00
Charles Kerr ebc612d725 get encrypted uTorrent working. 2007-09-22 03:37:37 +00:00
Charles Kerr 56b0e5d1ac * remove some console messages.
* scrape sooner when peers are added.
* added stub code for the connection manager code
2007-09-22 00:22:10 +00:00
Charles Kerr e9ed5e28d9 * accept tiennou's partial patch for `fast peers' extension
* fix growl problem I introduced in the last checkin, reported by chrissturm
2007-09-21 14:50:29 +00:00
Charles Kerr 6479ecbcf6 fix crash reported by Gimp_, John_Clay, and persept_ 2007-09-21 04:41:44 +00:00
Charles Kerr 28bcf6204b clamp down on the flood of debug messages. 2007-09-20 23:33:46 +00:00
Charles Kerr 379beed969 if we're seeding, disconnect from other seeds (part 1 of 2) 2007-09-20 23:07:36 +00:00
Mitchell Livingston 76da1185ca merge encryption branch to trunk (xcode project is still out of date) 2007-09-20 16:32:01 +00:00