aboutsummaryrefslogtreecommitdiff
path: root/net.cpp
diff options
context:
space:
mode:
authors_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2010-11-19 20:22:46 +0000
committers_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2010-11-19 20:22:46 +0000
commit683bcb9154422011ef01e8c5677bad2c4b323436 (patch)
treef6828938d68ad3c941723d4dd031bd1db8f058d9 /net.cpp
parentc4679ad0f1d4370d2d441c5091358d16854b8102 (diff)
downloadbitcoin-683bcb9154422011ef01e8c5677bad2c4b323436.tar.xz
efficiently sort transaction dependencies in one pass
git-svn-id: https://bitcoin.svn.sourceforge.net/svnroot/bitcoin/trunk@184 1a98c847-1fd6-4fd8-948a-caf3550aa51b
Diffstat (limited to 'net.cpp')
-rw-r--r--net.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/net.cpp b/net.cpp
index 7cc21be398..3c80644a49 100644
--- a/net.cpp
+++ b/net.cpp
@@ -178,41 +178,41 @@ bool GetMyExternalIP(unsigned int& ipRet)
{
if (nHost == 1)
{
- addrConnect = CAddress("72.233.89.199:80"); // www.whatismyip.com
+ addrConnect = CAddress("91.198.22.70:80"); // checkip.dyndns.org
if (nLookup == 1)
{
- struct hostent* phostent = gethostbyname("www.whatismyip.com");
+ struct hostent* phostent = gethostbyname("checkip.dyndns.org");
if (phostent && phostent->h_addr_list && phostent->h_addr_list[0])
addrConnect = CAddress(*(u_long*)phostent->h_addr_list[0], htons(80));
}
- pszGet = "GET /automation/n09230945.asp HTTP/1.1\r\n"
- "Host: www.whatismyip.com\r\n"
- "User-Agent: Bitcoin/1.0 (see www.bitcoin.org)\r\n"
+ pszGet = "GET / HTTP/1.1\r\n"
+ "Host: checkip.dyndns.org\r\n"
+ "User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)\r\n"
"Connection: close\r\n"
"\r\n";
- pszKeyword = NULL; // Returns just IP address
+ pszKeyword = "Address:";
}
else if (nHost == 2)
{
- addrConnect = CAddress("91.198.22.70:80"); // checkip.dyndns.org
+ addrConnect = CAddress("74.208.43.192:80"); // www.showmyip.com
if (nLookup == 1)
{
- struct hostent* phostent = gethostbyname("checkip.dyndns.org");
+ struct hostent* phostent = gethostbyname("www.showmyip.com");
if (phostent && phostent->h_addr_list && phostent->h_addr_list[0])
addrConnect = CAddress(*(u_long*)phostent->h_addr_list[0], htons(80));
}
- pszGet = "GET / HTTP/1.1\r\n"
- "Host: checkip.dyndns.org\r\n"
+ pszGet = "GET /simple/ HTTP/1.1\r\n"
+ "Host: www.showmyip.com\r\n"
"User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)\r\n"
"Connection: close\r\n"
"\r\n";
- pszKeyword = "Address:";
+ pszKeyword = NULL; // Returns just IP address
}
if (GetMyExternalIP2(addrConnect, pszGet, pszKeyword, ipRet))