From 1e7248b330bde4c70528ccf91535391e19294dc3 Mon Sep 17 00:00:00 2001 From: Dirk Engling Date: Sat, 7 Nov 2026 16:54:36 +0100 Subject: Add a knob to help reducing memory consumption. This time: empty torrents may expire sooner --- src/trackerlogic.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/trackerlogic.h') diff --git a/src/trackerlogic.h b/src/trackerlogic.h index 6b53406..c4b7774 100644 --- a/src/trackerlogic.h +++ b/src/trackerlogic.h @@ -44,6 +44,11 @@ typedef struct { #define OT_TORRENT_TIMEOUT_HOURS 24 #define OT_TORRENT_TIMEOUT (60 * OT_TORRENT_TIMEOUT_HOURS) +/* How long a torrent kept only for its download count, with no peers in either + family, is held, in minutes. Defaults to OT_TORRENT_TIMEOUT and is lowered by + tracker.empty_torrent_timeout. */ +extern ot_time g_empty_torrent_timeout; + #define OT_CLIENT_REQUEST_INTERVAL_RANDOM \ (OT_CLIENT_REQUEST_INTERVAL - OT_CLIENT_REQUEST_VARIATION / 2 + (int)(nrand48(ws->rand48_state) % OT_CLIENT_REQUEST_VARIATION)) #define OT_CLIENT_REJECT_INTERVAL_RANDOM \ -- cgit v1.3