From 00d8e207b4849583a6cff954e5bb4d73130b5964 Mon Sep 17 00:00:00 2001 From: Victor Grishchenko Date: Wed, 12 May 2010 17:07:01 +0200 Subject: [PATCH] OS gives random port no anyway --- swift.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/swift.cpp b/swift.cpp index 211448a..e391520 100644 --- a/swift.cpp +++ b/swift.cpp @@ -111,7 +111,7 @@ int main (int argc, char** argv) { quit("cant listen to %s\n",bindaddr.str()) } else if (tracker!=Address() || http_gw!=Address()) { // leeching for (int i=0; i<=10; i++) { - bindaddr = Address((uint32_t)INADDR_ANY,1024+rand()%10000); + bindaddr = Address((uint32_t)INADDR_ANY,0); if (Listen(bindaddr)>0) break; if (i==10) -- 2.20.1