Browse Source

maybe core works

release/v0.1
jl777 9 years ago
parent
commit
5743d752a7
  1. 2
      iguana/SuperNET.c
  2. 2
      iguana/iguana_instantdex.c
  3. 1
      iguana/iguana_rpc.c
  4. BIN
      iguana/pnacl/Release/iguana.pexe

2
iguana/SuperNET.c

@ -1295,7 +1295,7 @@ FOUR_STRINGS(SuperNET,login,handle,password,permanentfile,passphrase)
{ {
printf("decrypted.(%s)\n",decryptstr); printf("decrypted.(%s)\n",decryptstr);
free(decryptstr); free(decryptstr);
if ( (passphrase= jstr(argjson,"passphrase")) != 0 ) if ( (passphrase= jstr(argjson,"result")) != 0 )
{ {
SuperNET_setkeys(myinfo,passphrase,(int32_t)strlen(passphrase),1); SuperNET_setkeys(myinfo,passphrase,(int32_t)strlen(passphrase),1);
free_json(argjson); free_json(argjson);

2
iguana/iguana_instantdex.c

@ -177,8 +177,8 @@ char *instantdex_request(struct supernet_info *myinfo,struct instantdex_msghdr *
rel = jstr(argjson,"rel"); rel = jstr(argjson,"rel");
volume = jdouble(argjson,"volume"); volume = jdouble(argjson,"volume");
aveprice = instantdex_aveprice(myinfo,sortbuf,(int32_t)(sizeof(sortbuf)/sizeof(*sortbuf)),&totalvol,base,rel,volume,argjson); aveprice = instantdex_aveprice(myinfo,sortbuf,(int32_t)(sizeof(sortbuf)/sizeof(*sortbuf)),&totalvol,base,rel,volume,argjson);
printf("aveprice %.8f vol %f\n",aveprice,volume);
return(clonestr("{\"result\":\"request calculated aveprice\"}")); return(clonestr("{\"result\":\"request calculated aveprice\"}"));
return(clonestr("{\"error\":\"request missing parameter\"}"));
} else return(clonestr("{\"error\":\"request needs argjson\"}")); } else return(clonestr("{\"error\":\"request needs argjson\"}"));
} }

1
iguana/iguana_rpc.c

@ -723,7 +723,6 @@ char *SuperNET_rpcparse(struct supernet_info *myinfo,char *retbuf,int32_t bufsiz
{ {
*jsonflagp = 1; *jsonflagp = 1;
SuperNET_htmlstr("index7778.html",retbuf,bufsize,0); SuperNET_htmlstr("index7778.html",retbuf,bufsize,0);
//return(retbuf);
return(OS_filestr(&filesize,"index7778.html")); return(OS_filestr(&filesize,"index7778.html"));
} }
if ( strncmp(&url[i],"/api",strlen("/api")) == 0 ) if ( strncmp(&url[i],"/api",strlen("/api")) == 0 )

BIN
iguana/pnacl/Release/iguana.pexe

Binary file not shown.
Loading…
Cancel
Save