Commit Graph

71 Commits

Author SHA1 Message Date
Jordan Lee 4c8bda8805 function pointer type correctness. mikedld 2013-09-08 17:08:18 +00:00
Jordan Lee 8dd572076a (trunk, libT) #5429 'nightly build crashes on webseed torrents' -- fixed. 2013-07-20 16:45:02 +00:00
Jordan Lee 96786b7fa1 (trunk) update web.h's API s.t. there's an explicit function to use when downloading webseed content. 2013-04-13 20:25:28 +00:00
Jordan Lee 96691dd019 (libT) make the class hierarchy between tr_peer, tr_peerMsgs, and tr_webseed a little less ad-hoc 2013-02-04 16:23:33 +00:00
Jordan Lee 553bd58681 (libT) peer-mgr doesn't care about non-piece data being transferred, so don't notify it when it happens 2013-01-30 18:00:03 +00:00
Jordan Lee c1559f3cc4 (trunk, libT) first drop of the tr_quark patch. 2012-12-22 20:35:19 +00:00
Jordan Lee 3d38723ad9 Follow more common whitespace style conventions in the C code (libtransmission, daemon, utils, cli, gtk). 2012-12-05 17:29:46 +00:00
Jordan Lee e1e254d8c2 fix NULL-pointer-dereference regression introduced in r13546 for #5069. 2012-10-13 17:32:23 +00:00
Jordan Lee 3398a48e57 (trunk libT) #4402 "Transmission Bandwidth allocation getting overflows" -- use gvdl's patch '4402-uint-bpsoverflow.patch' 2012-07-01 02:17:35 +00:00
Jordan Lee 1cfeb4debb (trunk libT) #4644 "Transmission can't download big files from webseed." -- fix overflow error with a patch based on one from and_cesbo. (Modified by Jordan to add random bugs.) 2011-12-10 18:42:52 +00:00
Jordan Lee 6add3fb940 (trunk web) small refactoring of webseed's batch processing.
1. move the callback structs' declarations next to the callback functions where they're used.
2. rename the callback structs to clarify their link to the callback functions.
3. constify some of the callback functions' local variables.
4. clarify some of the comments.
2011-09-12 21:46:15 +00:00
Jordan Lee 3a39486cf1 tr_free() already checks for null, so no need for the caller to wrap it in an 'if not null' test 2011-09-12 20:41:28 +00:00
Jordan Lee 10734ab7bc remove two redundant variables from tr_webseed_task 2011-09-12 20:40:09 +00:00
Jordan Lee fd6e7a7fbd (trunk libT) #4445 "transmission only downloads partially from webseeds with redirections" -- fixed with patch from alexat. 2011-09-12 05:39:27 +00:00
Jordan Lee b3db349c83 (trunk libt) #4437 'multi file webseeds do not work' -- revert r12740, which was a bad patch. 2011-09-06 16:10:27 +00:00
Jordan Lee 6c61d6ac67 (trunk libT) #4437 "Multi file webseeds don't work" -- fixed. 2011-08-25 09:08:50 +00:00
Jordan Lee bd6aaf9a12 (trunk libT) remove trailing spaces from a couple of lines of code 2011-07-17 18:11:34 +00:00
Jordan Lee 2317f08d38 (trunk libT) #4338 "improved webseed support" -- patch by alexat 2011-07-10 15:24:51 +00:00
Jordan Lee 7f2e4084dc (trunk libT) fix webseed issue reported by Alex Hartl 2011-05-29 14:59:00 +00:00
Jordan Lee 6e99c6cd69 (trunk libT) heap pruning: using the same mechanism as in r12388, avoid an unnecessary malloc+memcpy+free when building the URL for a webseed download request 2011-04-27 20:52:07 +00:00
Jordan Lee 1b02eb8641 (trunk libT) use aggregation for the tr_bandwidth objects owned by tr_session and tr_torrent 2011-03-31 14:53:22 +00:00
Jordan Lee 83c0e4f011 (trunk libT) break the mac build and introduce new crashes.
This is partially to address #4145 "Downloads stuck at 100%" by refactoring the bitset, bitfield, and tr_completion; however, the ripple effect is larger than usual so things may get worse in the short term before getting better.

livings124: to fix the mac build, remove bitset.[ch] from xcode
2011-03-28 16:31:05 +00:00
Jordan Lee b4d36aeb54 (trunk) #4138 "use stdbool.h instead of tr_bool" -- done. 2011-03-22 15:19:54 +00:00
Jordan Lee fee784f1d8 (trunk) #4081 "Add 'cookieString' argument 'torrent-add' method in RPC" -- done. 2011-03-15 04:22:47 +00:00
Jordan Lee 0c36e0c9de (trunk libT) remove the unused tr_ratecontrol code. switch webseed over to using tr_bandwidth. 2011-03-03 18:33:24 +00:00
Jordan Lee 2b9db3c242 (trunk libT) #4048 "use bitsets instead of bitfield in tr_completion" -- done.
Excuse the sprawl. Much of this didn't fit into self-contained commits.
2011-02-23 03:54:04 +00:00
Jordan Lee 5dffc2814d (trunk libT) #3767 "rarest first policy" -- fixed.
This commit, started by a patch from athy, implements a rarest first policy when deciding which pieces to request from peers. It keeps a count of how many peers have each piece, and updates the count when getting bitfields, have, have all, and have none messages, as well as decrementing the counts when peers disconnect.

This running total is generated only for downloading torrents. Seeds don't have this overhead.
2011-02-17 05:14:53 +00:00
Jordan Lee 716a3c90c2 (trunk) #4032 "Better error detection / reporting in http announces" -- added to trunk.
This patch adds two new flags to the callback function -- did_connect and did_timeout -- that are calculated inside of web.c using information from libcurl. This allows the announcer to detect timeouts more accurately and also to distinguish between unresponsive peers (which get the preexisting "Tracker did not respond" error message) and unconnectable peers (which get a new error message, "Could not connect to tracker").
2011-02-17 02:26:24 +00:00
Jordan Lee 2450d6514b (trunk libT) #3519 "Webseeds don't work" -- handle nonresponsive webseeds
Don't keep trying to use nonresponsive webseeds or it will generate unnecessary network traffic and kill us during endgame.
2011-02-03 04:17:48 +00:00
Jordan Lee 5b23aae320 (trunk libT) memory cache should use evbuffers to avoid unnecessary calls to memcpy -- done. 2011-01-29 18:56:53 +00:00
Jordan Lee 0aee598300 (trunk libT) #3937 "inactive webseeds are listed as active"
This is caused by libtransmission using tr_webseedIsActive() in two ways: (1) webseed.c uses it to know if there are any pending requests, and (2) tr_torrentStat() uses it to set tr_stat.webseedsSendingToUs. Having a queued task isn't enough to be "active" in use (2) -- it needs to know if the webseed is actually sending data. These two uses should be moved into separate functions.
2011-01-23 16:35:23 +00:00
Jordan Lee 92d1dfcfbf (trunk libT) very minor code cleanup -- use an enum instead of magic numbers, etc. 2011-01-06 15:12:12 +00:00
Jordan Lee 6dc03f471e (trunk libT) #3519 "webseeds don't work" -- fixed. 2011-01-06 01:00:21 +00:00
Charles Kerr e5bb3205a1 (trunk) Join the 21st century and use only 1 space at the end sentences. This commit is nearly as important as the semi-annual ones that remove trailing spaces from the ends of lines of code... :) 2010-12-27 19:18:17 +00:00
Charles Kerr 345b14adbc (trunk) #3836 "libevent2 support" -- bump libevent2 requirement to 2.0.10. This will break the Mac build for a minute intil BMW applies his Mac patch 2010-12-20 02:07:51 +00:00
Charles Kerr cdcc4705aa (trunk) #3045 "make libtransmission's API byte-oriented instead of KiB-oriented." -- implemented. This is a largish commit and will break the mac build for a little while. 2010-07-03 00:25:22 +00:00
Charles Kerr db44d81b24 (trunk) #3256 "libtransmission/publish.[ch] should be replaced" -- apply publish.diff for 2.10 2010-06-19 14:33:10 +00:00
Charles Kerr 546bca723b (trunk libT) #3159 "better decision-making when choosing which peers to initiate new connections with" -- experimental commit 2010-04-20 21:54:03 +00:00
Charles Kerr a334b422c3 (trunk) remove unnecessary #includes 2010-01-28 13:33:40 +00:00
Charles Kerr 5c26afdb52 happy new year! 2010-01-04 21:00:47 +00:00
Charles Kerr 21bd268aa9 (trunk libT) fix <assert.h> #includes 2010-01-01 22:14:50 +00:00
Charles Kerr 78ead8c3dd (trunk) update the copyright notices 2009-12-05 02:19:24 +00:00
Charles Kerr 63027e1d5a (trunk libT) resolve "noslashes" vs "keep_slashes" variable name inconsistency between the declaration and the definition of tr_http_escape() 2009-11-29 08:05:47 +00:00
Charles Kerr 94a48c4c81 (trunk libT) a very minor commit. remove trailing spaces from lines and other stuff like that 2009-11-22 03:57:36 +00:00
Charles Kerr 44df1d5548 (trunk libT) #2112: provide "ipv6=" parameter to trackers 2009-11-10 17:03:23 +00:00
Charles Kerr b906c125ac (trunk libT) #2548: T's request queue can send out too many duplicate requests 2009-11-08 23:20:00 +00:00
Charles Kerr 3680896a19 (trunk libT) #2508 atom->port never updated 2009-10-29 16:10:03 +00:00
Charles Kerr ef21704b58 (trunk libT) remove the last calls to tr_getBuffer() and tr_releaseBuffer() 2009-06-14 01:00:36 +00:00
Charles Kerr 509465a85b (trunk libT) partial revert of r7825: back out the refillPulse() changes 2009-02-11 16:34:35 +00:00
Charles Kerr 08289b9d13 (trunk libT) #1748: possible fix for the kqueue corruption errors by consolidating the three per-torrent libevent timers into three session-wide timers. Since most people reporting this error have lots of torrents loaded, consider a hypothetical example: if you had 500 torrents, this patch will reduce 1,500 libevent timers down to just three timers. On top of that, those three have simpler life cycles too... 2009-02-04 16:58:52 +00:00