Partial revert
This commit is contained in:
@@ -116,6 +116,7 @@ struct CC_info
|
|||||||
|
|
||||||
uint8_t didinit;
|
uint8_t didinit;
|
||||||
};
|
};
|
||||||
|
typedef struct CC_info CCcontract_info;
|
||||||
struct CC_info *CCinit(struct CC_info *cp,uint8_t evalcode);
|
struct CC_info *CCinit(struct CC_info *cp,uint8_t evalcode);
|
||||||
|
|
||||||
struct oracleprice_info
|
struct oracleprice_info
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ class TokenHelper;
|
|||||||
|
|
||||||
// Plan validation runner, it may be called twice - for coins and tokens
|
// Plan validation runner, it may be called twice - for coins and tokens
|
||||||
// (sadly we cannot have yet 'templatized' lambdas, if we could we could capture all these params inside HeirValidation()...)
|
// (sadly we cannot have yet 'templatized' lambdas, if we could we could capture all these params inside HeirValidation()...)
|
||||||
template <typename Helper> bool RunValidationPlans(uint8_t funcId, struct CC_info* cp, Eval* eval, const CTransaction& tx, uint256 latestTxid, CScript fundingOpretScript, uint8_t hasHeirSpendingBegun)
|
template <typename Helper> bool RunValidationPlans(uint8_t funcId, struct CCcontract_info* cp, Eval* eval, const CTransaction& tx, uint256 latestTxid, CScript fundingOpretScript, uint8_t hasHeirSpendingBegun)
|
||||||
{
|
{
|
||||||
int32_t numvins = tx.vin.size();
|
int32_t numvins = tx.vin.size();
|
||||||
int32_t numvouts = tx.vout.size();
|
int32_t numvouts = tx.vout.size();
|
||||||
@@ -104,14 +104,14 @@ template <typename Helper> bool RunValidationPlans(uint8_t funcId, struct CC_inf
|
|||||||
/**
|
/**
|
||||||
* Tx validation entry function
|
* Tx validation entry function
|
||||||
*/
|
*/
|
||||||
bool HeirValidate(struct CC_info* cpHeir, Eval* eval, const CTransaction& tx, uint32_t nIn)
|
bool HeirValidate(struct CCcontract_info* cpHeir, Eval* eval, const CTransaction& tx, uint32_t nIn)
|
||||||
{
|
{
|
||||||
int32_t numvins = tx.vin.size();
|
int32_t numvins = tx.vin.size();
|
||||||
int32_t numvouts = tx.vout.size();
|
int32_t numvouts = tx.vout.size();
|
||||||
//int32_t preventCCvins = -1;
|
//int32_t preventCCvins = -1;
|
||||||
//int32_t preventCCvouts = -1;
|
//int32_t preventCCvouts = -1;
|
||||||
|
|
||||||
struct CC_info *cpTokens, tokensC;
|
struct CCcontract_info *cpTokens, tokensC;
|
||||||
cpTokens = CCinit(&tokensC, EVAL_TOKENS);
|
cpTokens = CCinit(&tokensC, EVAL_TOKENS);
|
||||||
|
|
||||||
if (numvouts < 1)
|
if (numvouts < 1)
|
||||||
@@ -237,7 +237,7 @@ bool HeirValidate(struct CC_info* cpHeir, Eval* eval, const CTransaction& tx, ui
|
|||||||
* Checks if vout is to cryptocondition address
|
* Checks if vout is to cryptocondition address
|
||||||
* @return vout value in satoshis
|
* @return vout value in satoshis
|
||||||
*/
|
*/
|
||||||
template <class Helper> int64_t IsHeirFundingVout(struct CC_info* cp, const CTransaction& tx, int32_t voutIndex, CPubKey ownerPubkey, CPubKey heirPubkey)
|
template <class Helper> int64_t IsHeirFundingVout(struct CCcontract_info* cp, const CTransaction& tx, int32_t voutIndex, CPubKey ownerPubkey, CPubKey heirPubkey)
|
||||||
{
|
{
|
||||||
char destaddr[65], heirFundingAddr[65];
|
char destaddr[65], heirFundingAddr[65];
|
||||||
|
|
||||||
@@ -437,7 +437,7 @@ uint256 _FindLatestFundingTx(uint256 fundingtxid, uint8_t& funcId, uint256 &toke
|
|||||||
|
|
||||||
// TODO: correct cc addr:
|
// TODO: correct cc addr:
|
||||||
std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue>> unspentOutputs;
|
std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue>> unspentOutputs;
|
||||||
struct CC_info *cp, C;
|
struct CCcontract_info *cp, C;
|
||||||
cp = CCinit(&C, EVAL_HEIR);
|
cp = CCinit(&C, EVAL_HEIR);
|
||||||
char coinaddr[64];
|
char coinaddr[64];
|
||||||
GetCCaddress1of2(cp, coinaddr, ownerPubkey, heirPubkey); // get the address of cryptocondition '1 of 2 pubkeys'
|
GetCCaddress1of2(cp, coinaddr, ownerPubkey, heirPubkey); // get the address of cryptocondition '1 of 2 pubkeys'
|
||||||
@@ -507,7 +507,7 @@ uint256 FindLatestFundingTx(uint256 fundingtxid, uint8_t& funcId, uint256 &token
|
|||||||
}
|
}
|
||||||
|
|
||||||
// add inputs of 1 of 2 cc address
|
// add inputs of 1 of 2 cc address
|
||||||
template <class Helper> int64_t Add1of2AddressInputs(struct CC_info* cp, uint256 fundingtxid, CMutableTransaction& mtx, CPubKey ownerPubkey, CPubKey heirPubkey, int64_t total, int32_t maxinputs)
|
template <class Helper> int64_t Add1of2AddressInputs(struct CCcontract_info* cp, uint256 fundingtxid, CMutableTransaction& mtx, CPubKey ownerPubkey, CPubKey heirPubkey, int64_t total, int32_t maxinputs)
|
||||||
{
|
{
|
||||||
// TODO: add threshold check
|
// TODO: add threshold check
|
||||||
int64_t nValue, voutValue, totalinputs = 0;
|
int64_t nValue, voutValue, totalinputs = 0;
|
||||||
@@ -566,7 +566,7 @@ template <class Helper> int64_t Add1of2AddressInputs(struct CC_info* cp, uint256
|
|||||||
/**
|
/**
|
||||||
* enumerate all tx's sending to CCHeir 1of2address and calc total lifetime funds
|
* enumerate all tx's sending to CCHeir 1of2address and calc total lifetime funds
|
||||||
*/
|
*/
|
||||||
template <class Helper> int64_t LifetimeHeirContractFunds(struct CC_info* cp, uint256 fundingtxid, CPubKey ownerPubkey, CPubKey heirPubkey)
|
template <class Helper> int64_t LifetimeHeirContractFunds(struct CCcontract_info* cp, uint256 fundingtxid, CPubKey ownerPubkey, CPubKey heirPubkey)
|
||||||
{
|
{
|
||||||
char coinaddr[64];
|
char coinaddr[64];
|
||||||
Helper::GetCoinsOrTokensCCaddress1of2(coinaddr, ownerPubkey, heirPubkey); // get the address of cryptocondition '1 of 2 pubkeys'
|
Helper::GetCoinsOrTokensCCaddress1of2(coinaddr, ownerPubkey, heirPubkey); // get the address of cryptocondition '1 of 2 pubkeys'
|
||||||
@@ -619,7 +619,7 @@ template <typename Helper> UniValue HeirFund(uint64_t txfee, int64_t amount, std
|
|||||||
{
|
{
|
||||||
UniValue result(UniValue::VOBJ);
|
UniValue result(UniValue::VOBJ);
|
||||||
CMutableTransaction mtx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), komodo_nextheight());
|
CMutableTransaction mtx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), komodo_nextheight());
|
||||||
struct CC_info *cp, C;
|
struct CCcontract_info *cp, C;
|
||||||
|
|
||||||
cp = CCinit(&C, Helper::getMyEval());
|
cp = CCinit(&C, Helper::getMyEval());
|
||||||
if (txfee == 0)
|
if (txfee == 0)
|
||||||
@@ -707,7 +707,7 @@ template <class Helper> UniValue _HeirAdd(uint256 fundingtxid, uint64_t txfee, i
|
|||||||
UniValue result(UniValue::VOBJ);
|
UniValue result(UniValue::VOBJ);
|
||||||
CMutableTransaction mtx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), komodo_nextheight());
|
CMutableTransaction mtx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), komodo_nextheight());
|
||||||
int64_t inputs, CCchange = 0;
|
int64_t inputs, CCchange = 0;
|
||||||
struct CC_info *cp, C;
|
struct CCcontract_info *cp, C;
|
||||||
std::string rawhex;
|
std::string rawhex;
|
||||||
|
|
||||||
cp = CCinit(&C, Helper::getMyEval()); // for tokens shoud be EVAL_TOKENS to sign it correctly!
|
cp = CCinit(&C, Helper::getMyEval()); // for tokens shoud be EVAL_TOKENS to sign it correctly!
|
||||||
@@ -825,7 +825,7 @@ template <typename Helper>UniValue _HeirClaim(uint256 fundingtxid, uint64_t txfe
|
|||||||
CMutableTransaction mtx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), komodo_nextheight());
|
CMutableTransaction mtx = CreateNewContextualCMutableTransaction(Params().GetConsensus(), komodo_nextheight());
|
||||||
CPubKey myPubkey;
|
CPubKey myPubkey;
|
||||||
int64_t inputs, change = 0;
|
int64_t inputs, change = 0;
|
||||||
struct CC_info *cp, C;
|
struct CCcontract_info *cp, C;
|
||||||
|
|
||||||
cp = CCinit(&C, EVAL_HEIR);
|
cp = CCinit(&C, EVAL_HEIR);
|
||||||
if (txfee == 0)
|
if (txfee == 0)
|
||||||
@@ -1006,7 +1006,7 @@ UniValue HeirInfo(uint256 fundingtxid)
|
|||||||
return result;
|
return result;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
struct CC_info *cp, C;
|
struct CCcontract_info *cp, C;
|
||||||
cp = CCinit(&C, EVAL_HEIR);
|
cp = CCinit(&C, EVAL_HEIR);
|
||||||
|
|
||||||
uint8_t hasHeirSpendingBegun = 0;
|
uint8_t hasHeirSpendingBegun = 0;
|
||||||
@@ -1123,7 +1123,7 @@ UniValue HeirInfo(uint256 fundingtxid)
|
|||||||
* @return list of heir plan handles (fundingtxid)
|
* @return list of heir plan handles (fundingtxid)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
template <typename Helper>void _HeirList(struct CC_info *cp, UniValue &result)
|
template <typename Helper>void _HeirList(struct CCcontract_info *cp, UniValue &result)
|
||||||
{
|
{
|
||||||
std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue>> unspentOutputs;
|
std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue>> unspentOutputs;
|
||||||
char coinaddr[64];
|
char coinaddr[64];
|
||||||
@@ -1174,7 +1174,7 @@ UniValue HeirList()
|
|||||||
UniValue result(UniValue::VOBJ);
|
UniValue result(UniValue::VOBJ);
|
||||||
result.push_back(Pair("result", "success"));
|
result.push_back(Pair("result", "success"));
|
||||||
|
|
||||||
struct CC_info *cpHeir, *cpTokens, heirC, tokenC; // NOTE we must use a separate 'C' structure for each CCinit!
|
struct CCcontract_info *cpHeir, *cpTokens, heirC, tokenC; // NOTE we must use a separate 'C' structure for each CCinit!
|
||||||
|
|
||||||
cpHeir = CCinit(&heirC, EVAL_HEIR);
|
cpHeir = CCinit(&heirC, EVAL_HEIR);
|
||||||
cpTokens = CCinit(&tokenC, EVAL_TOKENS);
|
cpTokens = CCinit(&tokenC, EVAL_TOKENS);
|
||||||
@@ -1185,4 +1185,3 @@ UniValue HeirList()
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -47,11 +47,11 @@ public:
|
|||||||
return CTxOut(amount, CScript() << ParseHex(HexStr(myPubkey)) << OP_CHECKSIG);
|
return CTxOut(amount, CScript() << ParseHex(HexStr(myPubkey)) << OP_CHECKSIG);
|
||||||
} */
|
} */
|
||||||
static bool GetCoinsOrTokensCCaddress1of2(char *coinaddr, CPubKey ownerPubkey, CPubKey heirPubkey) {
|
static bool GetCoinsOrTokensCCaddress1of2(char *coinaddr, CPubKey ownerPubkey, CPubKey heirPubkey) {
|
||||||
struct CC_info *cpHeir, heirC;
|
struct CCcontract_info *cpHeir, heirC;
|
||||||
cpHeir = CCinit(&heirC, EVAL_HEIR);
|
cpHeir = CCinit(&heirC, EVAL_HEIR);
|
||||||
return GetCCaddress1of2(cpHeir, coinaddr, ownerPubkey, heirPubkey);
|
return GetCCaddress1of2(cpHeir, coinaddr, ownerPubkey, heirPubkey);
|
||||||
}
|
}
|
||||||
static void CCaddrCoinsOrTokens1of2set(struct CC_info *cp, CPubKey ownerPubkey, CPubKey heirPubkey, char *coinaddr) {
|
static void CCaddrCoinsOrTokens1of2set(struct CCcontract_info *cp, CPubKey ownerPubkey, CPubKey heirPubkey, char *coinaddr) {
|
||||||
CCaddr1of2set(cp, ownerPubkey, heirPubkey, coinaddr);
|
CCaddr1of2set(cp, ownerPubkey, heirPubkey, coinaddr);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -61,7 +61,7 @@ class TokenHelper {
|
|||||||
public:
|
public:
|
||||||
static uint8_t getMyEval() { return EVAL_TOKENS; }
|
static uint8_t getMyEval() { return EVAL_TOKENS; }
|
||||||
static int64_t addOwnerInputs(uint256 tokenid, CMutableTransaction& mtx, CPubKey ownerPubkey, int64_t total, int32_t maxinputs) {
|
static int64_t addOwnerInputs(uint256 tokenid, CMutableTransaction& mtx, CPubKey ownerPubkey, int64_t total, int32_t maxinputs) {
|
||||||
struct CC_info *cpHeir, heirC;
|
struct CCcontract_info *cpHeir, heirC;
|
||||||
cpHeir = CCinit(&heirC, EVAL_TOKENS);
|
cpHeir = CCinit(&heirC, EVAL_TOKENS);
|
||||||
return AddTokenCCInputs(cpHeir, mtx, ownerPubkey, tokenid, total, maxinputs);
|
return AddTokenCCInputs(cpHeir, mtx, ownerPubkey, tokenid, total, maxinputs);
|
||||||
}
|
}
|
||||||
@@ -89,12 +89,12 @@ public:
|
|||||||
return MakeCC1vout(EVAL_TOKENS, amount, myPubkey); // yes EVAL_TOKENS
|
return MakeCC1vout(EVAL_TOKENS, amount, myPubkey); // yes EVAL_TOKENS
|
||||||
} */
|
} */
|
||||||
static bool GetCoinsOrTokensCCaddress1of2(char *coinaddr, CPubKey ownerPubkey, CPubKey heirPubkey) {
|
static bool GetCoinsOrTokensCCaddress1of2(char *coinaddr, CPubKey ownerPubkey, CPubKey heirPubkey) {
|
||||||
struct CC_info *cpHeir, heirC;
|
struct CCcontract_info *cpHeir, heirC;
|
||||||
cpHeir = CCinit(&heirC, EVAL_HEIR);
|
cpHeir = CCinit(&heirC, EVAL_HEIR);
|
||||||
return GetTokensCCaddress1of2(cpHeir, coinaddr, ownerPubkey, heirPubkey);
|
return GetTokensCCaddress1of2(cpHeir, coinaddr, ownerPubkey, heirPubkey);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void CCaddrCoinsOrTokens1of2set(struct CC_info *cp, CPubKey ownerPubkey, CPubKey heirPubkey, char *coinaddr) {
|
static void CCaddrCoinsOrTokens1of2set(struct CCcontract_info *cp, CPubKey ownerPubkey, CPubKey heirPubkey, char *coinaddr) {
|
||||||
|
|
||||||
CCaddrTokens1of2set(cp, ownerPubkey, heirPubkey, coinaddr);
|
CCaddrTokens1of2set(cp, ownerPubkey, heirPubkey, coinaddr);
|
||||||
}
|
}
|
||||||
@@ -123,13 +123,13 @@ public:
|
|||||||
class CValidatorBase
|
class CValidatorBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CValidatorBase(CC_info* cp) : m_cp(cp) {}
|
CValidatorBase(CCcontract_info* cp) : m_cp(cp) {}
|
||||||
virtual bool isVinValidator() const = 0;
|
virtual bool isVinValidator() const = 0;
|
||||||
virtual bool validateVin(CTxIn vin, CTxOut prevVout, std::string& message) const = 0;
|
virtual bool validateVin(CTxIn vin, CTxOut prevVout, std::string& message) const = 0;
|
||||||
virtual bool validateVout(CTxOut vout, std::string& message) const = 0;
|
virtual bool validateVout(CTxOut vout, std::string& message) const = 0;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CC_info * m_cp;
|
CCcontract_info * m_cp;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -138,11 +138,11 @@ protected:
|
|||||||
class CInputIdentifierBase
|
class CInputIdentifierBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CInputIdentifierBase(CC_info* cp) : m_cp(cp) {}
|
CInputIdentifierBase(CCcontract_info* cp) : m_cp(cp) {}
|
||||||
virtual std::string inputName() const = 0;
|
virtual std::string inputName() const = 0;
|
||||||
virtual bool identifyInput(CTxIn vin) const = 0;
|
virtual bool identifyInput(CTxIn vin) const = 0;
|
||||||
protected:
|
protected:
|
||||||
CC_info * m_cp;
|
CCcontract_info * m_cp;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -375,7 +375,7 @@ private:
|
|||||||
|
|
||||||
class CNormalInputIdentifier : CInputIdentifierBase {
|
class CNormalInputIdentifier : CInputIdentifierBase {
|
||||||
public:
|
public:
|
||||||
CNormalInputIdentifier(CC_info* cp) : CInputIdentifierBase(cp) {}
|
CNormalInputIdentifier(CCcontract_info* cp) : CInputIdentifierBase(cp) {}
|
||||||
virtual std::string inputName() const { return std::string("normal input"); }
|
virtual std::string inputName() const { return std::string("normal input"); }
|
||||||
virtual bool identifyInput(CTxIn vin) const {
|
virtual bool identifyInput(CTxIn vin) const {
|
||||||
return !IsCCInput(vin.scriptSig);
|
return !IsCCInput(vin.scriptSig);
|
||||||
@@ -384,7 +384,7 @@ public:
|
|||||||
|
|
||||||
class CCCInputIdentifier : CInputIdentifierBase {
|
class CCCInputIdentifier : CInputIdentifierBase {
|
||||||
public:
|
public:
|
||||||
CCCInputIdentifier(CC_info* cp) : CInputIdentifierBase(cp) {}
|
CCCInputIdentifier(CCcontract_info* cp) : CInputIdentifierBase(cp) {}
|
||||||
virtual std::string inputName() const { return std::string("CC input"); }
|
virtual std::string inputName() const { return std::string("CC input"); }
|
||||||
virtual bool identifyInput(CTxIn vin) const {
|
virtual bool identifyInput(CTxIn vin) const {
|
||||||
return IsCCInput(vin.scriptSig);
|
return IsCCInput(vin.scriptSig);
|
||||||
@@ -398,7 +398,7 @@ public:
|
|||||||
template <class Helper> class CCC1of2AddressValidator : CValidatorBase
|
template <class Helper> class CCC1of2AddressValidator : CValidatorBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CCC1of2AddressValidator(CC_info* cp, CScript opRetScript, std::string customMessage = "") :
|
CCC1of2AddressValidator(CCcontract_info* cp, CScript opRetScript, std::string customMessage = "") :
|
||||||
m_fundingOpretScript(opRetScript), m_customMessage(customMessage), CValidatorBase(cp) {}
|
m_fundingOpretScript(opRetScript), m_customMessage(customMessage), CValidatorBase(cp) {}
|
||||||
|
|
||||||
virtual bool isVinValidator() const { return false; }
|
virtual bool isVinValidator() const { return false; }
|
||||||
@@ -452,7 +452,7 @@ private:
|
|||||||
template <class Helper> class CMyPubkeyVoutValidator : CValidatorBase
|
template <class Helper> class CMyPubkeyVoutValidator : CValidatorBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CMyPubkeyVoutValidator(CC_info* cp, CScript opRetScript, bool checkNormals)
|
CMyPubkeyVoutValidator(CCcontract_info* cp, CScript opRetScript, bool checkNormals)
|
||||||
: m_fundingOpretScript(opRetScript), m_checkNormals(checkNormals), CValidatorBase(cp) { }
|
: m_fundingOpretScript(opRetScript), m_checkNormals(checkNormals), CValidatorBase(cp) { }
|
||||||
|
|
||||||
virtual bool isVinValidator() const { return false; }
|
virtual bool isVinValidator() const { return false; }
|
||||||
@@ -512,7 +512,7 @@ private:
|
|||||||
template <class Helper> class CHeirSpendValidator : CValidatorBase
|
template <class Helper> class CHeirSpendValidator : CValidatorBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CHeirSpendValidator(CC_info* cp, CScript opRetScript, uint256 latesttxid, uint8_t isHeirSpendingBegan)
|
CHeirSpendValidator(CCcontract_info* cp, CScript opRetScript, uint256 latesttxid, uint8_t isHeirSpendingBegan)
|
||||||
: m_fundingOpretScript(opRetScript), m_latesttxid(latesttxid), m_isHeirSpendingBegan(isHeirSpendingBegan), CValidatorBase(cp) {}
|
: m_fundingOpretScript(opRetScript), m_latesttxid(latesttxid), m_isHeirSpendingBegan(isHeirSpendingBegan), CValidatorBase(cp) {}
|
||||||
|
|
||||||
virtual bool isVinValidator() const { return false; }
|
virtual bool isVinValidator() const { return false; }
|
||||||
@@ -568,7 +568,7 @@ private:
|
|||||||
template <class Helper> class COpRetValidator : CValidatorBase
|
template <class Helper> class COpRetValidator : CValidatorBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
COpRetValidator(CC_info* cp, CScript opret)
|
COpRetValidator(CCcontract_info* cp, CScript opret)
|
||||||
: m_fundingOpretScript(opret), CValidatorBase(cp) {}
|
: m_fundingOpretScript(opret), CValidatorBase(cp) {}
|
||||||
|
|
||||||
virtual bool isVinValidator() const { return false; }
|
virtual bool isVinValidator() const { return false; }
|
||||||
@@ -619,7 +619,7 @@ private:
|
|||||||
template <class Helper> class CNullValidator : CValidatorBase
|
template <class Helper> class CNullValidator : CValidatorBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
CNullValidator(CC_info* cp)
|
CNullValidator(CCcontract_info* cp)
|
||||||
: CValidatorBase(cp) { }
|
: CValidatorBase(cp) { }
|
||||||
|
|
||||||
virtual bool isVinValidator() const { return false; }
|
virtual bool isVinValidator() const { return false; }
|
||||||
|
|||||||
@@ -136,7 +136,7 @@ std::vector<CCcontract_info> &GetCryptoConditions()
|
|||||||
return vCC;
|
return vCC;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool GetCCByUnspendableAddress(struct CC_info *cp, char *addrstr)
|
bool GetCCByUnspendableAddress(struct CCcontract_info *cp, char *addrstr)
|
||||||
{
|
{
|
||||||
std::vector<CCcontract_info> &vCC = GetCryptoConditions();
|
std::vector<CCcontract_info> &vCC = GetCryptoConditions();
|
||||||
bool found = false;
|
bool found = false;
|
||||||
@@ -153,7 +153,7 @@ bool GetCCByUnspendableAddress(struct CC_info *cp, char *addrstr)
|
|||||||
return found;
|
return found;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CCinitLite(struct CC_info *cp, uint8_t evalcode)
|
bool CCinitLite(struct CCcontract_info *cp, uint8_t evalcode)
|
||||||
{
|
{
|
||||||
std::vector<CCcontract_info> &vCC = GetCryptoConditions();
|
std::vector<CCcontract_info> &vCC = GetCryptoConditions();
|
||||||
bool found = false;
|
bool found = false;
|
||||||
|
|||||||
Reference in New Issue
Block a user