fix
This commit is contained in:
@@ -700,6 +700,12 @@ void komodo_init(int32_t height)
|
|||||||
{
|
{
|
||||||
pthread_mutex_init(&komodo_mutex,NULL);
|
pthread_mutex_init(&komodo_mutex,NULL);
|
||||||
decode_hex(NOTARY_PUBKEY33,33,(char *)NOTARY_PUBKEY.c_str());
|
decode_hex(NOTARY_PUBKEY33,33,(char *)NOTARY_PUBKEY.c_str());
|
||||||
|
#ifdef SERVER
|
||||||
|
char Raddress[18];
|
||||||
|
pubkey2addr((char *)Raddress,(uint8_t *)NOTARY_PUBKEY33);
|
||||||
|
CBitcoinAddress address(Raddress);
|
||||||
|
NOTARY_ADDRESS = address.ToString();
|
||||||
|
#endif
|
||||||
if ( height >= 0 )
|
if ( height >= 0 )
|
||||||
{
|
{
|
||||||
n = (int32_t)(sizeof(Notaries_genesis)/sizeof(*Notaries_genesis));
|
n = (int32_t)(sizeof(Notaries_genesis)/sizeof(*Notaries_genesis));
|
||||||
|
|||||||
@@ -1484,15 +1484,10 @@ char *iguanafmtstr = (char *)"curl --url \"http://127.0.0.1:7776\" --data \"{\\\
|
|||||||
|
|
||||||
int32_t komodo_whoami(char *pubkeystr,int32_t height,uint32_t timestamp)
|
int32_t komodo_whoami(char *pubkeystr,int32_t height,uint32_t timestamp)
|
||||||
{
|
{
|
||||||
int32_t i,notaryid; char Raddress[18];
|
int32_t i,notaryid;
|
||||||
for (i=0; i<33; i++)
|
for (i=0; i<33; i++)
|
||||||
sprintf(&pubkeystr[i<<1],"%02x",NOTARY_PUBKEY33[i]);
|
sprintf(&pubkeystr[i<<1],"%02x",NOTARY_PUBKEY33[i]);
|
||||||
pubkeystr[66] = 0;
|
pubkeystr[66] = 0;
|
||||||
#ifdef SERVER
|
|
||||||
pubkey2addr((char *)Raddress,(uint8_t *)NOTARY_PUBKEY33);
|
|
||||||
CBitcoinAddress address(Raddress);
|
|
||||||
NOTARY_ADDRESS = address.ToString();
|
|
||||||
#endif
|
|
||||||
komodo_chosennotary(¬aryid,height,NOTARY_PUBKEY33,timestamp);
|
komodo_chosennotary(¬aryid,height,NOTARY_PUBKEY33,timestamp);
|
||||||
return(notaryid);
|
return(notaryid);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user