The changes in #5523 made two errors in the new implementation
1. tr_unix_address::to_string() got the ternary check backwards, leading
to always printing an empty string when the address is valid.
2. The inputs to tr_strvStartsWith in tr_unix_address::from_string()
were backwards as well, leading to the check failing for valid
socket addresses.
Co-authored-by: LaserEyess <LaserEyess@users.noreply.github.com>
* Revert "perf: use libsmall in libtransmission, pt 3 (#5653)"
This reverts commit 3b03494580.
* Revert "perf: use small in libtransmission (#5650)"
This reverts commit 559f6f0332.
* refactor: use BufferReader, BufferWriter in peer-socket
* feat: expose GrowthFactor in tr-buffer
* perf: choose better defaults for the peer message buffers
* chore: sync tests
* refactor: use small::map in ActiveRequests::Impl
Some languages use different percentage formatting style other than
100% (e.g. Turkish and French, %100-100 %). This commit enables the use
of NSNumberFormatter(), in order to provide localized formatting.
* refactor: reimplement Buffer using small
* refactor: use SmallBuffer in announcer-udp
* refactor: use SmallBuffer in variant-json
* refactor: use SmallBuffer in variant-benc
* refactor: use SmallBuffer in handshake
* refactor: use SmallBuffer in peer-msgs
* refactor: delete move semantics on stack-based buffers
* refactor: use std::map instead of QMap in PrefsDialog.cc
* refactor: use std::map instead of QMap in DetailsDialog.cc
* refactor: use std::map instead of QMap in OptionsDialog.cc
* refactor: use std::map instead of QMap in FileTreeModel.cc
* fixup: dedup tr_rpc_address with tr_address
tr_rpc_address was duplicating a lot of work that tr_address was doing a
lot better. Fall back to using tr_address for ipv4/ipv6 connections and
make a tr_unix_addr for handling unix sockets.
* remove unnecessary functions
`tr_parseNum<>()` is implemented with `fast_float::from_chars()`, and
the latter is documented as "expecting a locale-indepent format
equivalent to what is used by std::strtod in the default ("C") locale".
To accomodate locale independent number parsing, switch back to
locale-independent number formatting in `tr_truncd()` by both removing a
`L` format specifier from `fmt::format_to_n()` call and using a fixed
"." decimal separator when truncating the value.
* Expose files' begin and end pieces via RPC
This adds two arguments, `beginPiece` and `endPiece`, for each of the entries
in the `files` array of the RPC's `torrent-`get` method.
The point is to allow RPC clients to display a file's completion progress as
piece-based in addition to byte-based.
In many cases the webui code is not updated for core libtransmission
changes and changes in the utils/clients. Therefore, check to see if any
web changes are made before running npm linting.
Co-authored-by: LaserEyess <LaserEyess@users.noreply.github.com>