From 502492912b704745ebdaf819ead9fb2dd0b1c558 Mon Sep 17 00:00:00 2001 From: jl777 Date: Tue, 21 Mar 2017 21:58:12 +0200 Subject: [PATCH] Height 250000 update --- .gitignore | 6 ++++++ iguana/iguana_payments.c | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index f3176906f..1d70ba0e5 100755 --- a/.gitignore +++ b/.gitignore @@ -210,3 +210,9 @@ iguana/DB/SWAPS/270159951-1269722638 iguana/DB/SWAPS/244991424-1008712592 iguana/confs/1cc0270abba7f4463a3dcb9908b9d875691a6773fe3cc1b4302233ed76665300 + +iguana/autoAPI.md + +iguana/confs/5228bcea7ae2515a29c3844673de6ee2acba53bf45724744a00ff4306f192912 + +iguana/confs/630929d976025fafde221c7358eb5805f4359bad3c6b8bd50ad3f6e0a9b5ce78 diff --git a/iguana/iguana_payments.c b/iguana/iguana_payments.c index cdb27e36c..842dd261c 100755 --- a/iguana/iguana_payments.c +++ b/iguana/iguana_payments.c @@ -348,20 +348,22 @@ uint64_t _iguana_interest(uint32_t now,int32_t chainheight,uint32_t txlocktime,u { if ( minutes > 365 * 24 * 60 ) minutes = 365 * 24 * 60; + if ( chainheight >= 250000 ) + minutes -= 59; denominator = (((uint64_t)365 * 24 * 60) / minutes); if ( denominator == 0 ) denominator = 1; // max KOMODO_INTEREST per transfer, do it at least annually! if ( value > 25000LL*SATOSHIDEN && chainheight > 155949 ) { numerator = (value / 20); // assumes 5%! - if ( chainheight < 300000 ) + if ( chainheight < 250000 ) interest = (numerator / denominator); else interest = (numerator * minutes) / ((uint64_t)365 * 24 * 60); } else if ( value >= 10*SATOSHIDEN ) { numerator = (value * KOMODO_INTEREST); - if ( chainheight < 300000 || numerator * minutes < 365 * 24 * 60 ) + if ( chainheight < 250000 || numerator * minutes < 365 * 24 * 60 ) interest = (numerator / denominator) / SATOSHIDEN; else interest = ((numerator * minutes) / ((uint64_t)365 * 24 * 60)) / SATOSHIDEN; }