diff --git a/src/generator.c b/src/generator.c index 7a96e095..e2d3d2a4 100644 --- a/src/generator.c +++ b/src/generator.c @@ -192,7 +192,6 @@ static void kill_server(server_instance_t *si) dealloc(cs->port); dealloc(cs->auth); dealloc(si->data); - dealloc(si); } static int gen_loop(proc_instance_t *pi) @@ -1315,6 +1314,7 @@ static int server_mode(ckpool_t *ckp, proc_instance_t *pi) for (i = 0; i < ckp->btcds; i++) { si = ckp->servers[i]; kill_server(si); + dealloc(si); } dealloc(ckp->servers); return ret;