1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-02-28 08:45:29 +00:00
Commit graph

5798 commits

Author SHA1 Message Date
Charles Kerr
b08e17beef fixup! refactor: add BufferReader, BufferWriter::reserve_space() (#5513)
chore: remove tracer fmt::print() statements
2023-05-12 11:47:01 -05:00
Charles Kerr
51fd7056ba
refactor: add BufferReader, BufferWriter::reserve_space() (#5513) 2023-05-12 11:15:15 -05:00
Charles Kerr
c61d8b7cf7
refactor: rename tr_tracker_view.host to .host_and_port for clarity (#5508) 2023-05-08 20:28:10 -05:00
Charles Kerr
0d3b321bac
refactor: use snake_case for libtransmission class methods (#5497) 2023-05-05 23:11:05 -05:00
tearfur
d65f9329cd
refactor: followup/cleanup of tr_global_ip_cache PR (#5498)
* remove tr_session::bindAddress()

* replace tr_net_hasIPv6 with tr_session::has_ip_protocol()

* update comment
2023-05-05 22:05:28 -05:00
kmikita
693d202a64
refactor: save stats.json periodically and when closing session #5476 (#5490) 2023-05-05 15:33:23 -05:00
tearfur
474a30ab2d
feat: add global IP cache, fix UDP connection failure warnings 2023-05-05 12:17:40 -05:00
Gary Elshaw
2f1d5a225c
fix: comment typos in libtransmission (#5473) 2023-04-30 13:29:29 -05:00
Mike Gelfand
e8fcb025a0
fix: use user-preferred locale (#5444)
* Use user-preferred locale

Previous fix adding `L` format specifier was correct but only fixed half
of the problem, as C++ locale is set up to be "C" by default. GTK client
used to call `setlocale(LC_ALL, "")` to set up user-preferred locale
which only affected C functions and `std::locale` (used by libfmt) was
unaware of those changes.

Apply the fix to all the binaries since they're all doing some sort of
output to the user and calling libtransmission helpers, as well as using
libfmt directly.

* Improve libtransmission's json-test

Set the locale C++ way to avoid any sort of inconsistencies, and also
restore it to the old one once finished testing.

* Improve transmission-show test runner script

Quote outputs to avoid CMake error about `message()` being called with
no arguments. Capture stderr to the same output file. Fallback to `git
diff` if `diff` wasn't found. A few other minor changes.
2023-04-27 09:10:33 -05:00
Charles Kerr
47667bab8d
fix: bug that prevented providing the final metadata piece (#5460)
Fixes bug in implementation of BEP 9

Xref: https://www.bittorrent.org/beps/bep_0009.html
2023-04-26 19:40:49 -05:00
Charles Kerr
1b6b85989c
feat: add generic favicon_cache class for reuse between Qt, GTK app (#5294) 2023-04-22 21:11:16 -05:00
Charles Kerr
9d2507c7e3
refactor: snake_case in libtransmission class methods (#5428) 2023-04-22 20:25:55 -05:00
Charles Kerr
7e7d8137a0
fixup! feat: Add BufferWriter class (#5154) (#5437) 2023-04-22 18:13:39 -05:00
Charles Kerr
9f8a7a656e
fix: Buffer::Buffer(Buffer&&) bug (#5435) 2023-04-22 16:10:09 -05:00
Charles Kerr
ce4ffc3bdb
fix: 5422 use-after-free in peerMsgs::canRead (#5425) 2023-04-20 13:18:53 -05:00
Charles Kerr
3044c14b10
perf: in Buffer::Iterator, defer evbuffer API calls (#5420) 2023-04-19 16:00:30 -05:00
Charles Kerr
f2aa3e197b
refactor: add tr_sys_dir_get_files() (#5412) 2023-04-18 16:23:20 -05:00
Charles Kerr
a8e01ac38d
fix: minor warnings (#5409)
* chore: fix readability-qualified-auto warnings

* chore: fix clang-analyzer-core.uninitialized.Branch warning

* fix: collision of key 'ERROR' in transmission-qt

* chore: silence -Wshadow warning

* chore: silence warning C4100: 'iter': unreferenced formal parameter

* chore: fix warning C4127: conditional expression is constant warning
2023-04-17 23:11:09 -05:00
Charles Kerr
7d86d67bc7
chore: prefer fmt/core.h over fmt/format.h (#5404) 2023-04-16 15:34:19 -05:00
Charles Kerr
3af9645615
refactor: add tr_address::is_any() (#5398)
As suggested by @tearfur

Xref: https://github.com/transmission/transmission/pull/5329#discussion_r1166236165
2023-04-15 19:30:20 -05:00
Kyle Sanderson
06c784f639
fix: uninitialized session_id_t values (#5396) 2023-04-15 00:07:07 -05:00
Charles Kerr
e91af26923
perf: remove staging step for outbound peer msgs (#5394)
Write non-piece peer messages directly to the peer's outbuf instead of
waiting for a pulse() message to refill it. This can help with latency
sending messages out.

Change the semantics of `tr_peerIo::get_write_buffer_space()`: this is
now interpreted as the preferred minimum size, rather than the maximum.
It's OK to enqueue an outgoing piece message as long as there's _some_
space left, even if the message is larger than that space.

Build peer messages with template fold expressions. This lets us move
all the message-building to a single function and add some sanity checks
to the outgoing messages.
2023-04-14 19:31:09 -05:00
Charles Kerr
9158ae7126
feat: add tr_bitfield::intersects() (#5155) 2023-04-14 18:45:46 -05:00
Charles Kerr
ed4919a4f4
feat: Add BufferWriter class (#5154) 2023-04-14 17:08:01 -05:00
midzer
68e965aa28
perf: pass by reference (#4876) 2023-04-14 17:06:26 -05:00
Charles Kerr
d445c7f061
fix: crash in peer stats (#5279) 2023-04-14 16:03:08 -05:00
Charles Kerr
d72cb67cfb
chore: include directory name in libtransmission #includes (#5308) 2023-04-14 14:33:23 -05:00
Pierre Dubouilh
ebfba686b0
feat: sequential download (#4795) 2023-04-14 11:47:54 -05:00
Cœur
afa9f64feb
refactor: align tr_formatter_speed_KBps with stringForSpeed: kb: mb: gb: (#5108) 2023-04-14 10:36:34 -05:00
Charles Kerr
63421489fe
refactor: tr_sys_dir_open() takes a std::string_view (#5380) 2023-04-14 09:31:46 -05:00
Charles Kerr
0e2b8d721c
fix: only torrent metainfo display-name as a fallback (#5378)
Fixes #5347.
2023-04-12 17:26:43 -05:00
Charles Kerr
e33d9536ef
fix: return success on RPC add-torrent duplicate (#5370)
Keep Transmission 3's behavior to avoid unannounced API change
2023-04-12 13:37:04 -05:00
Cœur
91717fe91d
fix: potential NSString leak in tr_strv_convert_utf8() 2023-04-11 17:36:22 -05:00
Charles Kerr
c76cb4db51
fix: silence torrent-metainfo warnings for cross_seed_entry, uid (#5365) 2023-04-10 11:07:43 -05:00
tearfur
931beba56f
fix: set log level before constructing tr_session (#5345) 2023-04-03 15:37:28 -05:00
tearfur
e68c72daa4
fix: tr_net_hasIPv6() (#5312) 2023-03-28 13:41:07 -05:00
tearfur
85a00625dc
fix: intermediate fix for HTTP announce behaviour affected by bind-address-ipv* (#5296) 2023-03-28 12:59:42 -05:00
Mike Gelfand
a216bd7cec
Use locale-dependent decimal separators for user-visible numbers (#5288)
This includes percents, ratios, sizes, speeds, etc. coming from shared
formatting helpers. Previously based on sprintf-like functions using
locale, now using libfmt which doesn't use locale by default and needs
to be instructed to do it explicitly.
2023-03-23 19:48:45 -05:00
Cœur
3e97d0b9c2
fix: The right operand of '<' is a garbage value (#5285) 2023-03-23 12:05:11 -05:00
Charles Kerr
d63165e8a4
perf: fix wishlist cpu load regression, pt. 2 (#5273) 2023-03-22 10:24:10 -05:00
Charles Kerr
25f38d5ff3
fix: wrong tier value in torrent get tracker stat response (#5274) 2023-03-21 20:23:08 -05:00
Charles Kerr
58ce7bd437
fix: 4.0.2 wishlist CPU perf regression pt. 1 (#5266) 2023-03-20 21:08:16 -05:00
Cœur
c60bb5b834
fix: crash when magnet dn isn't utf-8 (#5244) 2023-03-19 10:36:16 -05:00
Charles Kerr
5cc3bf8a97
fix: generate peer-id on launch (#5233) 2023-03-15 20:53:48 -05:00
Charles Kerr
3aeefec203
chore: remove unused header includes (#5227) 2023-03-14 18:36:15 -05:00
Charles Kerr
a87d39f3bd
fix: filter out peers with port 1 from DHT peer lists. (#5218) 2023-03-13 19:27:47 -05:00
Charles Kerr
6224b60728
fix: wrong error message when writing to incomplete dir (#5217) 2023-03-13 16:20:39 -05:00
Colin B
59a157ebde
feat: restore support for nonstandard path.utf-8 (#3454) 2023-03-13 13:58:59 -05:00
Charles Kerr
dabd29f2b2
fix: std::clamp() assertion failure in maxAvailableReqs() (#5203) 2023-03-11 22:25:21 -06:00
Charles Kerr
900281eb1c
fix: check tr_ctorSetFoo() return values before adding torrent via RPC (#5202) 2023-03-11 19:44:54 -06:00