mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-02 04:21:41 +01:00
test.py: Keep the ad hoc tests' ports below Linux's ephemeral ports
With offsets of up to 30000, a port net/adhoc/limits listened on could be one an outgoing connection was using, and the listen failed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
a0669ffbe4
commit
d12e19ed35
1 file changed
+3
-2
@@ -757,8 +757,9 @@ def flags_for(test):
|
||||
return test_flags[test]
|
||||
if test.startswith("net/adhoc/"):
|
||||
# A new port offset each run: a connection the last run made with the same ports is still in TCP
|
||||
# TIME_WAIT for a while, and connecting again fails.
|
||||
return ADHOC_FLAGS + ["--port-offset=%d" % random.randrange(10000, 30000)]
|
||||
# TIME_WAIT for a while, and connecting again fails. The tests' ports go up to 31000 (game mode's), and
|
||||
# have to stay below Linux's ephemeral ports (32768 and up), which outgoing connections hold.
|
||||
return ADHOC_FLAGS + ["--port-offset=%d" % random.randrange(1, 1700)]
|
||||
return None
|
||||
|
||||
def is_pair_test(test):
|
||||
|
||||
Reference in new issue
Block a user