From 1b8f20eaa78b71915f6b45162a6017a507586ab1 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Sat, 12 Jan 2013 04:44:41 -0800 Subject: [PATCH] Some tuning. --- src/cpp/ripple/LedgerMaster.cpp | 2 +- src/cpp/ripple/uint256.h | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/src/cpp/ripple/LedgerMaster.cpp b/src/cpp/ripple/LedgerMaster.cpp index 1bac9de87..05d28e3e8 100644 --- a/src/cpp/ripple/LedgerMaster.cpp +++ b/src/cpp/ripple/LedgerMaster.cpp @@ -194,7 +194,7 @@ bool LedgerMaster::acquireMissingLedger(Ledger::ref origLedger, const uint256& l theApp->getIOService().post(boost::bind(&LedgerMaster::missingAcquireComplete, this, mMissingLedger)); } - if (theApp->getMasterLedgerAcquire().getFetchCount() < 5) + if (theApp->getMasterLedgerAcquire().getFetchCount() < 3) { int count = 0; typedef std::pair u_pair; diff --git a/src/cpp/ripple/uint256.h b/src/cpp/ripple/uint256.h index c00a7624a..3ec6c45d4 100644 --- a/src/cpp/ripple/uint256.h +++ b/src/cpp/ripple/uint256.h @@ -423,10 +423,8 @@ public: uint256& operator=(const basetype& b) { - for (int i = 0; i < WIDTH; i++) - pn[i] = b.pn[i]; - - return *this; + if (pn != b.pn) + memcpy(pn, b.pn, sizeof(pn)); } uint256(uint64 b)