From f4342a1848c91a637a58e1c41ccb61c8a259fa09 Mon Sep 17 00:00:00 2001 From: jl777 Date: Mon, 8 Jul 2019 22:27:28 -1100 Subject: [PATCH] Test --- src/komodo_nSPV.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/komodo_nSPV.h b/src/komodo_nSPV.h index af16b94e4..0f8c555d3 100644 --- a/src/komodo_nSPV.h +++ b/src/komodo_nSPV.h @@ -435,7 +435,7 @@ bool NSPV_SignTx(CMutableTransaction &mtx,int32_t vini,int64_t utxovalue,const C int32_t NSPV_newnotariescount(CTransaction tx,uint8_t elected[64][33]) { - CPubKey pubkeys[64]; uint8_t sig[512]; CScript scriptPubKeys[64]; CMutableTransaction mtx(tx); int32_t vini,j,siglen,numsigs = 0; char *str; std::vector> vData; + CPubKey pubkeys[64]; uint8_t sig[512]; char coinaddr[64]; CScript scriptPubKeys[64]; CMutableTransaction mtx(tx); int32_t vini,j,siglen,numsigs = 0; char *str; std::vector> vData; for (j=0; j<64; j++) { pubkeys[j] = buf2pk(elected[j]); @@ -453,8 +453,9 @@ int32_t NSPV_newnotariescount(CTransaction tx,uint8_t elected[64][33]) fprintf(stderr," vData[0]\n"); for (j=0; j<64; j++) { + Getscriptaddress(coinaddr,scriptPubKeys[j]); NSPV_SignTx(mtx,vini,10000,scriptPubKeys[j]); // sets SIG_TXHASH - fprintf(stderr,"%d ",pubkeys[j].Verify(SIG_TXHASH,vData[0])); + fprintf(stderr,"%s.%d ",coinaddr,pubkeys[j].Verify(SIG_TXHASH,vData[0])); } fprintf(stderr," verifies\n"); }