diff options
| author | Philip Kaufmann <[email protected]> | 2012-09-23 12:55:05 +0200 |
|---|---|---|
| committer | Philip Kaufmann <[email protected]> | 2012-10-04 09:35:24 +0200 |
| commit | 81bbef26099eb54f4dcc32e45b5e0416857a330d (patch) | |
| tree | ebccf84ff2f56d1f6e02fbb410cc39b65c3fed6b /src/net.cpp | |
| parent | Merge branch '2012_09_fixwformat' of github.com:laanwj/bitcoin (diff) | |
| download | discoin-81bbef26099eb54f4dcc32e45b5e0416857a330d.tar.xz discoin-81bbef26099eb54f4dcc32e45b5e0416857a330d.zip | |
add LOCK() for proxy related data-structures
- fix #1560 by properly locking proxy related data-structures
- update GetProxy() and introduce GetNameProxy() to be able to use a
thread-safe local copy from proxyInfo and nameproxyInfo
- update usage of GetProxy() all over the source to match the new
behaviour, as it now fills a full proxyType object
- rename GetNameProxy() into HaveNameProxy() to be more clear
Diffstat (limited to 'src/net.cpp')
| -rw-r--r-- | src/net.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/net.cpp b/src/net.cpp index 7c327f5d3..5b5510a5b 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1185,7 +1185,7 @@ void ThreadDNSAddressSeed2(void* parg) printf("Loading addresses from DNS seeds (could take a while)\n"); for (unsigned int seed_idx = 0; seed_idx < ARRAYLEN(strDNSSeed); seed_idx++) { - if (GetNameProxy()) { + if (HaveNameProxy()) { AddOneShot(strDNSSeed[seed_idx][1]); } else { vector<CNetAddr> vaddr; @@ -1529,7 +1529,7 @@ void ThreadOpenAddedConnections2(void* parg) if (mapArgs.count("-addnode") == 0) return; - if (GetNameProxy()) { + if (HaveNameProxy()) { while(!fShutdown) { BOOST_FOREACH(string& strAddNode, mapMultiArgs["-addnode"]) { CAddress addr; |