Use sent port instead of source (#1158)

It looks like torrent clients don't use default listening for sending requests to trackers
This commit is contained in:
Cønstantine Kovalensky 2023-11-22 20:28:12 +04:00 committed by GitHub
commit 51e037ed44
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -139,9 +139,6 @@ $peer_hash = hash('xxh128', $passkey . $info_hash_hex . $port);
// Events
$stopped = ($event === 'stopped');
// Get the real port to help port-restricted NAT users
$port = $_SERVER['REMOTE_PORT'];
// Set seeder & complete
$complete = $seeder = ($left == 0) ? 1 : 0;