jl777 8 years ago
parent
commit
a6e1601961
  1. 2
      basilisk/basilisk_swap.c
  2. 6
      iguana/iguana_interpreter.c

2
basilisk/basilisk_swap.c

@ -331,7 +331,7 @@ int32_t basilisk_swapuserdata(uint8_t *userdata,int32_t pushpriv,bits256 privkey
{
userdata[len++] = sizeof(privkey);
for (i=0; i<sizeof(privkey); i++)
userdata[len++] = privkey.bytes[i];//sizeof(privkey) - 1 - i];
userdata[len++] = privkey.bytes[sizeof(privkey) - 1 - i];
}
userdata[len++] = 0x51 * ifpath; // ifpath == 1 -> if path, 0 -> else path
return(len);

6
iguana/iguana_interpreter.c

@ -1338,10 +1338,10 @@ int32_t bitcoin_assembler(struct iguana_info *coin,cJSON *logarray,uint8_t scrip
else if ( (op->flags & IGUANA_CRYPTOFLAG) != 0 )
{
uint8_t rmd160[20],revdata[0x100]; bits256 hash;
if ( (datalen= iguana_databuf(databuf,args[0])) <= sizeof(revdata) )
if ( (datalen= iguana_databuf(revdata,args[0])) <= sizeof(revdata) )
{
for (i=0; i<datalen; i++)
revdata[i] = databuf[datalen - 1 - i];
//for (i=0; i<datalen; i++)
// revdata[i] = databuf[datalen - 1 - i];
} else printf("datalen.%d too big for %d\n",datalen,(int32_t)sizeof(revdata));
switch ( op->opcode )
{

Loading…
Cancel
Save