Use Txid in COutpoint

This commit is contained in:
dergoegge
2023-10-11 14:53:04 +01:00
parent d752349029
commit 9e58c5bcd9
48 changed files with 124 additions and 114 deletions

View File

@@ -789,7 +789,6 @@ static bool rest_getutxos(const std::any& context, HTTPRequest* req, const std::
for (size_t i = (fCheckMemPool) ? 1 : 0; i < uriParts.size(); i++)
{
uint256 txid;
int32_t nOutput;
std::string strTxid = uriParts[i].substr(0, uriParts[i].find('-'));
std::string strOutput = uriParts[i].substr(uriParts[i].find('-')+1);
@@ -797,8 +796,7 @@ static bool rest_getutxos(const std::any& context, HTTPRequest* req, const std::
if (!ParseInt32(strOutput, &nOutput) || !IsHex(strTxid))
return RESTERR(req, HTTP_BAD_REQUEST, "Parse error");
txid.SetHex(strTxid);
vOutPoints.emplace_back(txid, (uint32_t)nOutput);
vOutPoints.emplace_back(TxidFromString(strTxid), (uint32_t)nOutput);
}
if (vOutPoints.size() > 0)