]> Git Repo - VerusCoin.git/commitdiff
test
authorjl777 <[email protected]>
Thu, 1 Dec 2016 14:16:33 +0000 (11:16 -0300)
committerjl777 <[email protected]>
Thu, 1 Dec 2016 14:16:33 +0000 (11:16 -0300)
src/rpcblockchain.cpp

index f78c27cdd3b727b56973243af10614258e5abb2f..b3e3a89120fb57cfe4983f66ba22aaf4795b127e 100644 (file)
@@ -711,6 +711,18 @@ int32_t gettxout_scriptPubKey(uint8_t *scriptPubKey,int32_t maxsize,uint256 txid
             scriptPubKey[i] = ptr[i];
         return(i);
     }
+    CTransaction tx;
+    uint256 hashBlock;
+    if ( GetTransaction(hash,tx,hashBlock,true) == 0 )
+        return(-1);
+    else
+    {
+        ptr = (uint8_t *)tx.vout[n].scriptPubKey.data();
+        m = tx.vout[n].scriptPubKey.size();
+        for (i=0; i<maxsize&&i<m; i++)
+            scriptPubKey[i] = ptr[i];
+        return(i);
+    }
     return(-1);
 }
 
This page took 0.02905 seconds and 4 git commands to generate.