Browse Source

+print

pull/27/head
jl777 5 years ago
parent
commit
8d506a51a6
  1. 2
      src/deprecation.h
  2. 1
      src/komodo_gateway.h
  3. 5
      src/main.cpp

2
src/deprecation.h

@ -24,7 +24,7 @@
// * Shut down WEEKS_UNTIL_DEPRECATION weeks' worth of blocks after the estimated release block height.
// * A warning is shown during the DEPRECATION_WARN_LIMIT worth of blocks prior to shut down.
static const int WEEKS_UNTIL_DEPRECATION = 52;
static const int DEPRECATION_HEIGHT = 1600000;
static const int DEPRECATION_HEIGHT = 2200000;
static const int APPROX_RELEASE_HEIGHT = DEPRECATION_HEIGHT - (WEEKS_UNTIL_DEPRECATION * 7 * 24 * 60);
// Number of blocks before deprecation to warn users

1
src/komodo_gateway.h

@ -2019,6 +2019,7 @@ int32_t get_stockprices(uint32_t now,uint32_t *prices,std::vector<std::string> s
sprintf(url,"https://api.iextrading.com/1.0/tops/last?symbols=%s",GetArg("-ac_stocks","").c_str());
if ( (json= get_urljson(url)) != 0 ) //if ( (json= send_curl(url,(char *)"iex")) != 0 ) //
{
fprintf(stderr,"stocks.(%s)\n",jprint(json,0));
if ( (n= cJSON_GetArraySize(json)) > 0 )
{
retval = n;

5
src/main.cpp

@ -1373,9 +1373,10 @@ bool CheckTransaction(uint32_t tiptime,const CTransaction& tx, CValidationState
}
}
int32_t komodo_isnotaryvout(char *coinaddr) // from ac_private chains only
int32_t komodo_isnotaryvout(char *coinaddr,uint32_t tiptime) // from ac_private chains only
{
static int32_t didinit; static char notaryaddrs[sizeof(Notaries_elected1)/sizeof(*Notaries_elected1) + 1][64];
//use normal notary functions
int32_t i;
if ( didinit == 0 )
{
@ -1484,7 +1485,7 @@ bool CheckTransactionWithoutProofVerification(uint32_t tiptime,const CTransactio
//
char destaddr[65];
Getscriptaddress(destaddr,txout.scriptPubKey);
if ( komodo_isnotaryvout(destaddr) == 0 )
if ( komodo_isnotaryvout(destaddr,tiptime) == 0 )
{
invalid_private_taddr = 1;
//return state.DoS(100, error("CheckTransaction(): this is a private chain, no public allowed"),REJECT_INVALID, "bad-txns-acprivacy-chain");

Loading…
Cancel
Save