From 683bcb9154422011ef01e8c5677bad2c4b323436 Mon Sep 17 00:00:00 2001 From: s_nakamoto Date: Fri, 19 Nov 2010 20:22:46 +0000 Subject: efficiently sort transaction dependencies in one pass git-svn-id: https://bitcoin.svn.sourceforge.net/svnroot/bitcoin/trunk@184 1a98c847-1fd6-4fd8-948a-caf3550aa51b --- net.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'net.cpp') 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)) -- cgit v1.2.3