Commit Graph

310 Commits

Author SHA1 Message Date
Mike Gelfand 43acd7e3e4
Remove Xcode project in favor of CMake (#4147)
* Compile images into an assets catalog

* Optionally sign resulting Mac bundle

* Move 3rd-party/utility/test targets to their own folders

* Enable ARC via compile options unconditionally

* Install base and localized resources into correct directory

This seems like a Xcode quirk: if subdirectory containing the resource file
matches the destination directory name (and probably if there's more than one
resource file being installed there), the resulting folder structure then
contains an extra subdirectory, i.e. Resources/dirname/dirname/resname.

* Group source files for better structure in IDEs (Xcode, VS)

* Remove Xcode project

Using Xcode is still possible via "Xcode" CMake generator.

* Use ad-hoc signature if one is not specified

* Always use ad-hoc signature on link, leave proper signing to CPack

* Install localized resources into correct directory (QL plugin)

* Don't include CTest (we don't use additional targets it provides)

* Revert "Remove Xcode project"

This reverts commit dc069f654f.
2022-11-12 20:01:57 +00:00
Charles Kerr 250e055c1d
fix: warnings from clang tidy sonarcloud coverity (#4143) 2022-11-12 09:53:09 -06:00
Charles Kerr 9e06cf8f2e
refactor: make DHT unblocking (#4122) 2022-11-11 10:09:24 -06:00
Charles Kerr 2d2270c7d9
fix: thread-sanitizer warnings in SandboxedTests (#4131) 2022-11-09 23:56:08 -06:00
Charles Kerr ab78759233
test: add libtransmission::Timer tests (#4121) 2022-11-08 16:20:21 -06:00
Charles Kerr 36edd516aa
refactor: replace tr_boundinfo with tr_session::BoundSocket (#4103) 2022-11-06 10:35:48 -06:00
Charles Kerr 831eb8d40f
refactor: make `tr_session_thread` a unique_ptr owned by tr_session (#4069) 2022-11-04 16:20:27 -05:00
Charles Kerr e065565cd4
reafctor: use getaddrinfo() instead of evdns (#4094) 2022-11-04 13:29:56 -05:00
Charles Kerr ee8a6bd130
refactor: simplify blocklist code (#4086) 2022-11-03 15:46:27 -05:00
Charles Kerr 611d36ac84
refactor: decouple session settings from the session class (#4053) 2022-11-01 19:32:26 -05:00
A Cœur 14f2698cdc
Remove tr_generateAllowedSet declaration (#4029) 2022-10-25 08:50:53 -05:00
Charles Kerr b32f3e0a24
refactor: add tr_address::toCompact() (#4014)
* refactor: add tr_address::toCompact()

* test: use the theory.org compact ipv4/6 examples in NetTest.compact4, NetTest.compact6

* refactor: add tr_address::toCompact()

* test: add toCompact, fromCompact tests

* refactor: add compact <--> sockaddr_storage conversion
2022-10-24 13:40:12 -05:00
Mike Gelfand 70f623f32b
Add user data parameter for torrent removal callback (#4009) 2022-10-23 11:51:35 -05:00
Charles Kerr d191a04228
refactor: decouple tr_announcer_udp (#4002) 2022-10-21 13:15:14 -05:00
Charles Kerr 450f1dcadc
refactor: extract `tr_buffer` class from `tr_peerIo` (#3986) 2022-10-19 11:42:08 -05:00
Charles Kerr 7ee76a604d
feat: add libtransmission::Dns.cached() (#3984) 2022-10-17 20:17:01 -05:00
Charles Kerr c8e652c820
refactor: add dns interface class (#3977) 2022-10-17 14:41:42 -05:00
Charles Kerr 79068c512a
refactor: decouple tr-dht from peerMsgs, peerMgr (#3966)
* refactor: decouple peer-mgr from tr-dht

* refactor: remove tr_dhtPort()

* refactor: decouple peer-msgs from tr-dht

* refactor: make tr_udp_core.udp_port_ const

* refactor: rename tr_udp_core::dhtUninit() as startShutdown()
2022-10-15 08:22:43 -05:00
Charles Kerr 572e1bb50f
refactor: add tr_address::fromSockaddr() (#3964)
* refactor: remove TR_DISCARD_ALIGN

* refactor: add tr_address::fromSockaddr()
2022-10-14 01:20:39 -05:00
A Cœur 4ea9c87fea
fix: some typos (#3904) 2022-10-13 09:35:10 -05:00
Dzmitry Neviadomski ecc7c185a4
tests: Fix SubprocessTest on macOS Monterey and later. (#3812)
On macOS Monterey and later `/var` is symlinked to `/private/var`

Add missing `tr_sys_path_resolve(...)` for parent dir in sandbox
fixture.

Signed-off-by: Dzmitry Neviadomski <nevack.d@gmail.com>
2022-10-08 22:18:39 +03:00
Charles Kerr 89d6533cd7
build: support semver versioning (#3867)
* build: semver versioning

Xref: https://github.com/transmission/transmission/issues/1037

* test: add base62 tests for client-id

* build: include PATCH_VERSION in Transmission.rc.in

* build: semver versioning in version.h

* fixup! build: semver versioning in version.h

undo experimental verison changes that were made for testing purposes

* Fixup version in MSI package filename

Co-authored-by: Mike Gelfand <mikedld@mikedld.com>
2022-10-05 16:53:10 -05:00
Charles Kerr 257d98545b
refactor: add tr_port_forwarding::Mediator (#3855)
* refactor: add a Mediator class to decouple tr_session and tr_port_forwarding

* refactor: add tr_port_forwarding::Mediator::privatePeerPort()

* refactor: add tr_port_forwarding::Mediator::onPortForwarded()

* chore: avoid unnecessary include of timer.h in other headers

* refactor: use a uniform timerMaker() API in mediators
2022-10-01 09:12:49 -05:00
Harm133 1cd6c0464c
feat: Add IPv6 blocklist support (#3835) 2022-09-30 12:11:52 -05:00
Charles Kerr d82090658f
refactor: remove TR_PRIsv macros (#3842)
* refactor: remove TR_PRIsv from transmission-show

* refactor: remove TR_PRIsv from transmission-edit

* refactor: remove TR_PRIsv from transmission-remote

* refactor: remove TR_PRIsv from log.cc

* refactor: remove TR_PRIsv macro

* chore: remove FMT_STRING macro in transmission-edit

* refactor: use __android_log_write()
2022-09-23 14:36:37 -05:00
L2501 4977c1a02f
add clientIDs for BitTorrent Web, Free Download Manager 6, Torch Browser (#3838) 2022-09-22 16:55:51 -05:00
Charles Kerr 76fc42b659
test: fix watchdir CI flake (#3839) 2022-09-22 15:42:06 -05:00
Charles Kerr 80d9d5a63b
refactor: add tr_peerIo::peek() (#3798) 2022-09-09 13:12:47 -05:00
Charles Kerr c0f29a89ea
refactor: add [[nodiscard]] (#3793) 2022-09-08 21:49:51 -05:00
Charles Kerr 9fb590d3f5
fix: recent coverity warnings (#3788)
* fix: suppress intentional USE_AFTER_FREE in tests

* fix: unnecessary field check

* fix: in ~tr_verify_worker(), release mutex lock before waiting
2022-09-07 19:24:56 -05:00
Charles Kerr 82212ff1d8
refactor: move the verify worker thread into a wrapper class (#3775) 2022-09-05 23:43:59 -05:00
Charles Kerr ae74a13eb1
test: improve file-win32, file-posix test coverage (#3761) 2022-09-04 19:40:34 -05:00
L2501 22669dda5e
Add Advanced Download Manager & LibreTorrent client names (#3750) 2022-09-02 12:37:25 -05:00
Charles Kerr d130f7d593
refactor: prefer std::unique_ptr over std::shared_ptr (#3741) 2022-08-30 19:30:47 -05:00
Charles Kerr b7ea4d9f04
refactor: tr_peerIo ref, unref (#3735)
* refactor: replace manual peerIo refcounting with std::shared_ptr
2022-08-30 12:38:30 -05:00
Charles Kerr 7c014e3256
Refactor/tr peer io member funcs (#3734)
* refactor: make tr_peerIoSetEnabled() a member method

* refactor: make tr_peerIoFlushOutgoingProtocolMsgs() a member method

* refactor: make tr_peerIoFlush() a member method

* refactor: make tr_peerWriteBytes() a member method

* refactor: make tr_peerWriteBuf() a member method

* refactor: make tr_peerIoGetWriteBufferSpace() a member method

* chore: remove unused declaration

* refactor: make tr_peerIoUtpInit() a member method

* refactor: make tr_peerIoNew() a member method

* refactor: make tr_peerIoNewOutgoing() a member method

* refactor: make tr_peerIoNewIncoming() a member method
2022-08-29 15:58:18 -05:00
Charles Kerr cee339e10d
refactor: remove tr_removeElementFromArray() (#3731) 2022-08-28 21:51:26 -05:00
Charles Kerr 072bb0322c
refactor: remove tr_quark_get_string() (#3728) 2022-08-28 16:17:07 -05:00
Charles Kerr 4f3f0ccbeb
refactor: remove unused function tr_sys_file_seek() (#3727)
* refactor: remove TR_SYS_FILE_CREATE_NEW

* refactor: remove tr_sys_file_seek()
2022-08-28 14:10:00 -05:00
Charles Kerr 6c5fda2021
refactor: use std::ifstream in torrent-magnet (#3726) 2022-08-28 12:33:58 -05:00
Charles Kerr 185f1f96a5
test: add torrent-magnet tests (#3725) 2022-08-27 17:06:20 -05:00
Charles Kerr db3467b553
refactor: remove tr_sys file_map_for_reading() (#3723) 2022-08-27 14:05:21 -05:00
Greg Hazel fa8b6a5e0a
option to disable TCP (#3447) 2022-08-25 21:27:11 -05:00
Charles Kerr e8686095ed
refactor: local peer discovery (#3696) 2022-08-24 16:03:30 -05:00
Charles Kerr bbb1ba6ea3
refactor: tr_urlPercentEncode() (#3688) 2022-08-21 08:43:09 -05:00
Charles Kerr dde626d5e5
refactor: remove unused (#3675)
* refactor: remove unused define TR_PATH_DELIMITER_STR

* refactor: make TR_DEFAULT_BIND_ADDRESS_IPV4 private

* refactor: make TR_DEFAULT_BIND_ADDRESS_IPV6 private

* refactor: make TR_DEFAULT_RPC_HOST_WHITELIST private

* refactor: remove unused function tr_sessionSetRPCUrl()

* refactor: remove unused function tr_sessionGetRPCUrl()

* refactor: remove unused field native_local_path_prefix

* refactor: remove unused field native_unc_path_prefix
2022-08-18 22:47:23 -05:00
Charles Kerr c171d6df7c
refactor: remove tr_utf8_validate from public API (#3671)
it was only used as an impl helper, so make it private
2022-08-18 13:23:59 -05:00
Charles Kerr 963a8112a1
refactor: remove tr_strvDup() (#3666) 2022-08-17 21:18:44 -05:00
Charles Kerr bfec98c323
refactor: avoid tr_new() in transmission-remote (#3665) 2022-08-17 20:25:42 -05:00
Charles Kerr 29f57bc296
chore: iwyu headers (#3661) 2022-08-17 11:08:36 -05:00