Skip to content

Commit

Permalink
Merge branch 'amber-dev' of http://github.com/ambertime/amberchain in…
Browse files Browse the repository at this point in the history
…to amber-dev
  • Loading branch information
miozzz committed Sep 11, 2018
2 parents 71c105c + 84a5c3b commit d9e7d5e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
11 changes: 6 additions & 5 deletions src/core/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4512,11 +4512,12 @@ bool AcceptBlock(CBlock& block, CValidationState& state, CBlockIndex** ppindex,
return false;
}
}
else if (txFee > 0)
{
LogInvalidBlock(block, pindex, "AcceptBlock(): FAIL. Block should have an admin fee in the coinbase tx if there is a tx fee.\n");
return false;
}
// remove this check temporarily, as it was causing problems
// else if (txFee > 0 && adminFeeRatio > 0)
// {
// LogInvalidBlock(block, pindex, "AcceptBlock(): FAIL. Block should have an admin fee in the coinbase tx if there is a tx fee.\n");
// return false;
// }
}
}
}
Expand Down
3 changes: 2 additions & 1 deletion src/rpc/rpcstreams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3337,7 +3337,8 @@ Value appendrawsendfrom(const Array& params, bool fHelp)
Array unspentItems = listunspent(listunspent_params, fHelp).get_array();

std::string rawtx = params[0].get_str();
unsigned int nSize = rawtx.length();
// we estimate that this function will add around 500 bytes to the TX (generous allowance)
unsigned int nSize = rawtx.length() + 500;

// estimate the needed tx fee
unsigned int minRelayTxFee = StreamUtils::GetMinimumRelayTxFee();
Expand Down

0 comments on commit d9e7d5e

Please sign in to comment.