Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
define(_CLIENT_VERSION_MAJOR, 2)
define(_CLIENT_VERSION_MINOR, 1)
define(_CLIENT_VERSION_REVISION, 1)
define(_CLIENT_VERSION_REVISION, 2)
define(_CLIENT_VERSION_BUILD, 0)
define(_CLIENT_VERSION_IS_RELEASE, true)
define(_COPYRIGHT_YEAR, 2018)
Expand Down
11 changes: 8 additions & 3 deletions src/policy/policy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,11 @@ CAmount GetDustThreshold(const CTxOut& txout, const CFeeRate& dustRelayFeeIn)

bool IsDust(const CTxOut& txout, const CFeeRate& dustRelayFeeIn)
{
return (txout.nValue < GetDustThreshold(txout, dustRelayFeeIn));

if (txout.scriptPubKey.IsAssetScript())
return false;
else
return (txout.nValue < GetDustThreshold(txout, dustRelayFeeIn));
}

bool IsStandard(const CScript& scriptPubKey, txnouttype& whichType, const bool witnessEnabled)
Expand All @@ -73,11 +77,12 @@ bool IsStandard(const CScript& scriptPubKey, txnouttype& whichType, const bool w
} else if (whichType == TX_NULL_DATA &&
(!fAcceptDatacarrier || scriptPubKey.size() > nMaxDatacarrierBytes))
return false;

else if (!witnessEnabled && (whichType == TX_WITNESS_V0_KEYHASH || whichType == TX_WITNESS_V0_SCRIPTHASH))
return false;
else if (whichType == TX_TRANSFER_ASSET || whichType == TX_REISSUE_ASSET || whichType == TX_NEW_ASSET)
return true;

return whichType != TX_NONSTANDARD;
return whichType != TX_NONSTANDARD ;
}

bool IsStandardTx(const CTransaction& tx, std::string& reason, const bool witnessEnabled)
Expand Down