--- a/trb 0f001f3d19c9dcbaaf30450d656a95af86bfa1926a9efc217a7662bff29e77e7b56ac812d02a1cc6abecc35d33c2cbf7669e2d9ec1fb9a5b7022657970b67d94 +++ b/trb ef18e1cd46b1eae110ebe1dce85f02f37e5fd88c9c041902052a694c42948465f9c3cd3228182cb421d4dce57136e094d5548092213dd04068722e4a71c0a59d @@ -15306,7 +15306,7 @@ } ############################################################################## -57900 @ ./bitcoin/src/net.cpp +55940 @ ./bitcoin/src/net.cpp ############################################################################## // Copyright (c) 2009-2010 Satoshi Nakamoto // Copyright (c) 2009-2012 The Bitcoin developers @@ -15329,7 +15329,6 @@ void ThreadMessageHandler2(void* parg); void ThreadSocketHandler2(void* parg); void ThreadOpenConnections2(void* parg); -void ThreadDNSAddressSeed2(void* parg); bool OpenNetworkConnection(const CAddress& addrConnect); @@ -16377,92 +16376,6 @@ } - - - - - - - - - - - - - - - - - -static const char *strDNSSeed[] = { - "bitseed.xf2.org", - "dnsseed.bluematt.me", - "seed.bitcoin.sipa.be", - "dnsseed.bitcoin.dashjr.org", -}; - -void ThreadDNSAddressSeed(void* parg) -{ - IMPLEMENT_RANDOMIZE_STACK(ThreadDNSAddressSeed(parg)); - try - { - vnThreadsRunning[6]++; - ThreadDNSAddressSeed2(parg); - vnThreadsRunning[6]--; - } - catch (std::exception& e) { - vnThreadsRunning[6]--; - PrintException(&e, "ThreadDNSAddressSeed()"); - } catch (...) { - vnThreadsRunning[6]--; - throw; // support pthread_cancel() - } - printf("ThreadDNSAddressSeed exiting\n"); -} - -void ThreadDNSAddressSeed2(void* parg) -{ - printf("ThreadDNSAddressSeed started\n"); - int found = 0; - - if (!fTestNet) - { - printf("Loading addresses from DNS seeds (could take a while)\n"); - - for (int seed_idx = 0; seed_idx < ARRAYLEN(strDNSSeed); seed_idx++) { - vector vaddr; - if (Lookup(strDNSSeed[seed_idx], vaddr, NODE_NETWORK, -1, true)) - { - CAddrDB addrDB; - addrDB.TxnBegin(); - BOOST_FOREACH (CAddress& addr, vaddr) - { - if (addr.GetByte(3) != 127) - { - addr.nTime = 0; - AddAddress(addr, 0, &addrDB); - found++; - } - } - addrDB.TxnCommit(); // Save addresses (it's ok if this fails) - } - } - } - - printf("%d addresses found from DNS seeds\n", found); -} - - - - - - - - - - - - unsigned int pnSeed[] = { 0x959bd347, 0xf8de42b2, 0x73bc0518, 0xea6edc50, 0x21b00a4d, 0xc725b43d, 0xd665464d, 0x1a2a770e, @@ -16959,12 +16872,6 @@ // Start threads // - if (GetBoolArg("-nodnsseed")) - printf("DNS seeding disabled\n"); - else - if (!CreateThread(ThreadDNSAddressSeed, NULL)) - printf("Error: CreateThread(ThreadDNSAddressSeed) failed\n"); - // Get addresses from IRC and advertise ours if (!CreateThread(ThreadIRCSeed, NULL)) printf("Error: CreateThread(ThreadIRCSeed) failed\n"); @@ -17003,7 +16910,6 @@ if (vnThreadsRunning[2] > 0) printf("ThreadMessageHandler still running\n"); if (vnThreadsRunning[3] > 0) printf("ThreadBitcoinMiner still running\n"); if (vnThreadsRunning[4] > 0) printf("ThreadRPCServer still running\n"); - if (vnThreadsRunning[6] > 0) printf("ThreadDNSAddressSeed still running\n"); while (vnThreadsRunning[2] > 0 || vnThreadsRunning[4] > 0) Sleep(20); Sleep(50); @@ -20889,7 +20795,7 @@ } ############################################################################## -15775 @ ./bitcoin/src/init.cpp +15644 @ ./bitcoin/src/init.cpp ############################################################################## // Copyright (c) 2009-2010 Satoshi Nakamoto // Copyright (c) 2009-2012 The Bitcoin developers @@ -21060,7 +20966,6 @@ " -connect= \t\t " + _("Connect only to the specified node\n") + " -noirc \t " + _("Don't find peers using internet relay chat\n") + " -nolisten \t " + _("Don't accept connections from outside\n") + - " -nodnsseed \t " + _("Don't bootstrap list of peers using DNS\n") + " -banscore= \t " + _("Threshold for disconnecting misbehaving peers (default: 100)\n") + " -bantime= \t " + _("Number of seconds to keep misbehaving peers from reconnecting (default: 86400)\n") + " -maxreceivebuffer=\t " + _("Maximum per-connection receive buffer, *1000 bytes (default: 10000)\n") + @@ -21308,7 +21213,6 @@ // Note: the GetBoolArg() calls for all of these must happen later. SoftSetArg("-nolisten", true); SoftSetArg("-noirc", true); - SoftSetArg("-nodnsseed", true); SoftSetArg("-dns", false); }