This commit is contained in:
jl777
2019-07-11 15:23:20 -11:00
parent 4bbc78d527
commit 44cd71622c

View File

@@ -445,11 +445,15 @@ int64_t NSPV_AddNormalinputs(CMutableTransaction &mtx,CPubKey mypk,int64_t total
void NSPV_utxos2CCunspents(struct NSPV_utxosresp *ptr,std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue> > &outputs) void NSPV_utxos2CCunspents(struct NSPV_utxosresp *ptr,std::vector<std::pair<CAddressUnspentKey, CAddressUnspentValue> > &outputs)
{ {
CAddressUnspentKey key; CAddressUnspentValue value; int32_t i,type; uint160 hashBytes; std::string addrstr(ptr->coinaddr); CAddressUnspentKey key; CAddressUnspentValue value; int32_t i,type; uint160 hashBytes; std::string addrstr(ptr->coinaddr);
fprintf(stderr,"in converter\n");
if ( ptr->utxos != NULL && ptr->numutxos > 0 ) if ( ptr->utxos != NULL && ptr->numutxos > 0 )
{ {
CBitcoinAddress address(addrstr); CBitcoinAddress address(addrstr);
if (address.GetIndexKey(hashBytes, type, ptr->CCflag) == 0) if ( address.GetIndexKey(hashBytes, type, ptr->CCflag) == 0 )
{
fprintf(stderr,"couldnt get indexkey\n");
return; return;
}
for (i = 0; i < ptr->numutxos; i ++) for (i = 0; i < ptr->numutxos; i ++)
{ {
key.type = type; key.type = type;