diff --git a/src/komodo_utils.h b/src/komodo_utils.h index 02bdb07ad..a4af4da6f 100644 --- a/src/komodo_utils.h +++ b/src/komodo_utils.h @@ -1787,9 +1787,10 @@ void komodo_args(char *argv0) printf("KOMODO_REWIND %d\n",KOMODO_REWIND); } KOMODO_EARLYTXID = Parseuint256(GetArg("-earlytxid","0").c_str()); - if (KOMODO_EARLYTXID!=zeroid && (tx_height(KOMODO_EARLYTXID)==0 || tx_height(KOMODO_EARLYTXID)>100)) + CTransaction tx; uint256 blockhash; + if (KOMODO_EARLYTXID!=zeroid && myGetTransaction(KOMODO_EARLYTXID,tx,blockhash) && (mapBlockIndex[blockhash]->GetHeight() == 0 || mapBlockIndex[blockhash]->GetHeight() > 100)) { - fprintf(stderr,"earlytx can be only in first 100 blocks or does not exist\n"); + fprintf(stderr,"error: earlytx can be only in first 100 blocks or tx does not exist\n"); StartShutdown(); } ASSETCHAINS_EARLYTXIDCONTRACT = GetArg("-ac_earlytxidcontract",0);