Skip to content

Commit 8e71bf5

Browse files
poolerwo01
authored andcommitted
Fix memory leak in the long polling thread
1 parent cd28834 commit 8e71bf5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cpu-miner.c

+1
Original file line numberDiff line numberDiff line change
@@ -1327,6 +1327,7 @@ static void *longpoll_thread(void *userdata)
13271327
soval = json_object_get(res, "submitold");
13281328
submit_old = soval ? json_is_true(soval) : false;
13291329
pthread_mutex_lock(&g_work_lock);
1330+
work_free(&g_work);
13301331
if (have_gbt)
13311332
rc = gbt_work_decode(res, &g_work);
13321333
else

0 commit comments

Comments
 (0)