diff options
author | s_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b> | 2010-01-28 00:31:00 +0000 |
---|---|---|
committer | s_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b> | 2010-01-28 00:31:00 +0000 |
commit | cb0f89646f065800d38d7cfc10ba1e855563296a (patch) | |
tree | 2cef9a44c911d1a80ef48bc74d50e7cc86b512b9 /main.cpp | |
parent | 9a36562347122482fd1e6e77c74df66ad8cf2c3f (diff) |
simplify AddAddress,
readcompactsize limit,
fixed a 64-bit compile error in serialize.h,
change status "# blocks" to "# confirmations" and widen the column.
git-svn-id: https://bitcoin.svn.sourceforge.net/svnroot/bitcoin/trunk@53 1a98c847-1fd6-4fd8-948a-caf3550aa51b
Diffstat (limited to 'main.cpp')
-rw-r--r-- | main.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -1734,6 +1734,11 @@ bool ProcessMessages(CNode* pfrom) // Allow exceptions from underlength message on vRecv
printf("ProcessMessage(%s, %d bytes) : Exception '%s' caught, normally caused by a message being shorter than its stated length\n", strCommand.c_str(), nMessageSize, e.what());
}
+ else if (strstr(e.what(), ": size too large"))
+ {
+ // Allow exceptions from overlong size
+ printf("ProcessMessage(%s, %d bytes) : Exception '%s' caught\n", strCommand.c_str(), nMessageSize, e.what());
+ }
else
{
PrintException(&e, "ProcessMessage()");
@@ -1840,7 +1845,6 @@ bool ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv) return error("message addr size() = %d", vAddr.size());
// Store the new addresses
- CAddrDB addrdb;
foreach(CAddress& addr, vAddr)
{
if (fShutdown)
@@ -1848,7 +1852,7 @@ bool ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv) addr.nTime = GetAdjustedTime() - 2 * 60 * 60;
if (pfrom->fGetAddr)
addr.nTime -= 5 * 24 * 60 * 60;
- AddAddress(addrdb, addr, false);
+ AddAddress(addr, false);
pfrom->AddAddressKnown(addr);
if (!pfrom->fGetAddr && addr.IsRoutable())
{
|