Browse Source

Fix endianness of nonce submitted for stratum.

nfactor-troky
Con Kolivas 12 years ago
parent
commit
61360952f5
  1. 2
      cgminer.c

2
cgminer.c

@ -2738,7 +2738,7 @@ static void *submit_work_thread(void *userdata)
mutex_unlock(&sshare_lock); mutex_unlock(&sshare_lock);
sprintf(s, "{\"params\": [\"%s\", \"%s\", \"%s\", \"%s\", \"%08lx\"], \"id\": %d, \"method\": \"mining.submit\"}", sprintf(s, "{\"params\": [\"%s\", \"%s\", \"%s\", \"%s\", \"%08lx\"], \"id\": %d, \"method\": \"mining.submit\"}",
pool->rpc_user, work->job_id, work->nonce2, work->ntime, (unsigned long)work->blk.nonce, sshare->id); pool->rpc_user, work->job_id, work->nonce2, work->ntime, (unsigned long)htobe32(work->blk.nonce), sshare->id);
sock_send(pool->sock, s, strlen(s)); sock_send(pool->sock, s, strlen(s));

Loading…
Cancel
Save