From ef649813f8268ba8ae59c9b0ac1398090938de4a Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Sat, 15 Nov 2014 10:25:37 +1100 Subject: [PATCH] Dead stratum instances need not be in a doubly linked list --- src/stratifier.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stratifier.c b/src/stratifier.c index f48f7833..be5b316c 100644 --- a/src/stratifier.c +++ b/src/stratifier.c @@ -1231,7 +1231,7 @@ static void drop_client(sdata_t *sdata, int64_t id) else { if (client->user_instance) DL_DELETE(client->user_instance->instances, client); - DL_APPEND(sdata->dead_instances, client); + LL_PREPEND(sdata->dead_instances, client); } } ck_wunlock(&sdata->instance_lock); @@ -1249,7 +1249,7 @@ static void drop_client(sdata_t *sdata, int64_t id) DL_FOREACH_SAFE(sdata->dead_instances, client, tmp) { if (!client->ref) { LOGINFO("Stratifier discarding instance %ld", client->id); - DL_DELETE(sdata->dead_instances, client); + LL_DELETE(sdata->dead_instances, client); free(client->workername); free(client->useragent); free(client);