Browse Source

Fix minor memleak in submit_share

master
Con Kolivas 8 years ago
parent
commit
411076fb96
  1. 2
      src/generator.c

2
src/generator.c

@ -1466,7 +1466,7 @@ static void submit_share(gdata_t *gdata, json_t *val)
msg = ckzalloc(sizeof(stratum_msg_t)); msg = ckzalloc(sizeof(stratum_msg_t));
msg->json_msg = val; msg->json_msg = val;
share_id = add_share(gdata, client_id, proxi->diff); share_id = add_share(gdata, client_id, proxi->diff);
json_object_set_nocheck(val, "id", json_integer(share_id)); json_set_int(val, "id", share_id);
/* Add the new message to the psend list */ /* Add the new message to the psend list */
mutex_lock(&gdata->psend_lock); mutex_lock(&gdata->psend_lock);

Loading…
Cancel
Save