diff options
author | tiptorrent development team <tiptorrent@soleta.eu> | 2021-09-28 10:03:49 +0200 |
---|---|---|
committer | tiptorrent development team <tiptorrent@soleta.eu> | 2021-09-29 15:49:32 +0200 |
commit | 669089d6b14591691154f3cacd7c0e5d0a28bd0a (patch) | |
tree | ca718296621a8f24427b7007203ae68729c75309 | |
parent | 9c338ce302d42ae9a899fffa02835bdb26d5ec04 (diff) |
prioritize redirections over direct server download
testbed shows 95% use of redirections for data transfers.
-rw-r--r-- | src/handler.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/handler.c b/src/handler.c index 982ad02..2b9c6a0 100644 --- a/src/handler.c +++ b/src/handler.c @@ -160,8 +160,8 @@ int tip_client_state_process_payload(struct tip_client *cli) cli->allow_redirect = allow_redirect; num_clients++; - if (num_clients > max_clients) { - if (!tip_client_redirect(cli)) { + if (!tip_client_redirect(cli)) { + if (num_clients > max_clients) { tip_client_pending(cli); return 1; } |