Browse Source

Make invalid workinfo id use the current workbase id

master
Con Kolivas 10 years ago
parent
commit
27abc0e84f
  1. 1
      src/stratifier.c

1
src/stratifier.c

@ -1911,6 +1911,7 @@ static json_t *parse_submit(stratum_instance_t *client, json_t *json_msg,
ck_rlock(&workbase_lock); ck_rlock(&workbase_lock);
HASH_FIND_I64(workbases, &id, wb); HASH_FIND_I64(workbases, &id, wb);
if (unlikely(!wb)) { if (unlikely(!wb)) {
id = current_workbase->id;
err = SE_INVALID_JOBID; err = SE_INVALID_JOBID;
json_set_string(json_msg, "reject-reason", SHARE_ERR(err)); json_set_string(json_msg, "reject-reason", SHARE_ERR(err));
strcpy(idstring, job_id); strcpy(idstring, job_id);

Loading…
Cancel
Save