Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
a4d51308bf
  1. 1
      iguana/iguana_rpc.c
  2. 4
      iguana/main.c

1
iguana/iguana_rpc.c

@ -666,6 +666,7 @@ char *iguana_bitcoinRPC(struct supernet_info *myinfo,char *method,cJSON *json,ch
cJSON *params[16],*array; struct iguana_info *tmp,*coin = 0; char symbol[16]; int32_t i,c,n; char *retstr = 0;
symbol[0] = 0;
memset(params,0,sizeof(params));
printf("bitcoinRPC\n");
if ( json != 0 )
{
if ( port == myinfo->rpcport )

4
iguana/main.c

@ -156,7 +156,7 @@ char *iguana_JSON(char *jsonstr,uint16_t port)
char *SuperNET_jsonstr(struct supernet_info *myinfo,char *jsonstr,char *remoteaddr,uint16_t port)
{
cJSON *json; char *agent,*method,*retstr = 0;
//char str[65]; printf("SuperNET_jsonstr %p %s\n",&myinfo->privkey,bits256_str(str,myinfo->privkey));
printf("SuperNET_jsonstr.(%s)\n",jsonstr);
if ( (json= cJSON_Parse(jsonstr)) != 0 )
{
method = jstr(json,"method");
@ -191,7 +191,7 @@ int32_t iguana_jsonQ()
{
if ( (ptr->retjsonstr= SuperNET_jsonstr(ptr->myinfo,ptr->jsonstr,ptr->remoteaddr,ptr->port)) == 0 )
ptr->retjsonstr = clonestr("{\"error\":\"null return from iguana_jsonstr\"}");
//printf("finished.(%s) -> (%s) %.0f\n",ptr->jsonstr,*ptr->retjsonstrp!=0?*ptr->retjsonstrp:"null return",OS_milliseconds());
printf("finished.(%s) -> (%s) %.0f\n",ptr->jsonstr,ptr->retjsonstr!=0?ptr->retjsonstr:"null return",OS_milliseconds());
queue_enqueue("finishedQ",&finishedQ,&ptr->DL,0);
return(1);
}

Loading…
Cancel
Save