Introduce nOneWeek constant
[novacoin.git] / src / main.cpp
index dbd3276..970dd7e 100644 (file)
@@ -1762,7 +1762,8 @@ bool CBlock::ConnectBlock(CTxDB& txdb, CBlockIndex* pindex, bool fJustCheck)
 
             if (tx.nTime >= CHECKLOCKTIMEVERIFY_SWITCH_TIME) {
                 nFlags |= SCRIPT_VERIFY_CHECKLOCKTIMEVERIFY;
-                nFlags |= SCRIPT_VERIFY_CHECKSEQUENCEVERIFY;
+                // OP_CHECKSEQUENCEVERIFY is senseless without BIP68, so we're going disable it for now.
+                // nFlags |= SCRIPT_VERIFY_CHECKSEQUENCEVERIFY;
             }
 
             std::vector<CScriptCheck> vChecks;
@@ -2346,9 +2347,9 @@ bool CBlock::AcceptBlock()
         return DoS(100, error("AcceptBlock() : incorrect %s", IsProofOfWork() ? "proof-of-work" : "proof-of-stake"));
 
     int64_t nMedianTimePast = pindexPrev->GetMedianTimePast();
-    int nMaxOffset = 12 * 3600; // 12 hours
+    int nMaxOffset = 12 * nOneHour; // 12 hours
     if (pindexPrev->nTime < 1450569600)
-        nMaxOffset = 7 * 86400; // One week until 20 Dec, 2015
+        nMaxOffset = nOneWeek; // One week until 20 Dec, 2015
 
     // Check timestamp against prev
     if (GetBlockTime() <= nMedianTimePast || FutureDrift(GetBlockTime()) < pindexPrev->GetBlockTime())