aboutsummaryrefslogtreecommitdiff
path: root/main.cpp
diff options
context:
space:
mode:
authors_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2010-02-23 22:01:39 +0000
committers_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b>2010-02-23 22:01:39 +0000
commit30158c77e99a099cbdd556bacbac18b431c3870c (patch)
tree60f2b388dc78f0e25ce873a8ea4487393711b18e /main.cpp
parentee618d7540107aef543a0b252509b3005a15409c (diff)
run as daemon without GUI,
hooked wxApp::Initialize to ignore gtk-init-check failure if no GUI, fork to daemonize, rpc getinfo, getconnectioncount, getbalance, getgenerate, setgenerate, -- version 0.2.6
Diffstat (limited to 'main.cpp')
-rw-r--r--main.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/main.cpp b/main.cpp
index 56020a13ce..bd69de92a4 100644
--- a/main.cpp
+++ b/main.cpp
@@ -1315,11 +1315,10 @@ bool CBlock::AcceptBlock()
if (nTime <= pindexPrev->GetMedianTimePast())
return error("AcceptBlock() : block's timestamp is too early");
- // Check that all transactions are finalized (starting around Mar 2010)
- if (nBestHeight > 36000)
- foreach(const CTransaction& tx, vtx)
- if (!tx.IsFinal(nTime))
- return error("AcceptBlock() : contains a non-final transaction");
+ // Check that all transactions are finalized
+ foreach(const CTransaction& tx, vtx)
+ if (!tx.IsFinal(nTime))
+ return error("AcceptBlock() : contains a non-final transaction");
// Check proof of work
if (nBits != GetNextWorkRequired(pindexPrev))
@@ -1336,7 +1335,7 @@ bool CBlock::AcceptBlock()
return error("AcceptBlock() : AddToBlockIndex failed");
// Don't relay old inventory during initial block download.
- // Please keep this constant updated to a few thousand below current block count.
+ // Please keep this number updated to a few thousand below current block count.
if (hashBestChain == hash && nBestHeight > 40000)
RelayInventory(CInv(MSG_BLOCK, hash));
@@ -1556,8 +1555,8 @@ bool LoadBlockIndex(bool fAllowNew)
CTransaction txNew;
txNew.vin.resize(1);
txNew.vout.resize(1);
- txNew.vin[0].scriptSig = CScript() << 486604799 << CBigNum(4) << vector<unsigned char>((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp));
- txNew.vout[0].nValue = 50 * COIN;
+ txNew.vin[0].scriptSig = CScript() << 486604799 << CBigNum(4) << vector<unsigned char>((const unsigned char*)pszTimestamp, (const unsigned char*)pszTimestamp + strlen(pszTimestamp));
+ txNew.vout[0].nValue = 50 * COIN;
CBigNum bnPubKey;
bnPubKey.SetHex("0x5F1DF16B2B704C8A578D0BBAF74D385CDE12C11EE50455F3C438EF4C3FBCF649B6DE611FEAE06279A60939E028A8D65C10B73071A6F16719274855FEB0FD8A6704");
txNew.vout[0].scriptPubKey = CScript() << bnPubKey << OP_CHECKSIG;