Remove most memory leaks with valgrind

This commit is contained in:
2023-01-11 16:38:14 +01:00
parent 32f00175e4
commit 487386158d
7 changed files with 68 additions and 42 deletions

View File

@ -29,12 +29,14 @@ void proxy_handler_func(client_ctx_t *ctx) {
if (ret == 1) {
proxy_unlock_ctx(ctx->proxy);
ctx->proxy->client = NULL;
ctx->proxy = NULL;
} else if (ctx->use_proxy == 0) {
proxy_close(ctx->proxy);
} else if (ctx->use_proxy == 1) {
proxy_handler_2(ctx);
proxy_unlock_ctx(ctx->proxy);
ctx->proxy->client = NULL;
ctx->proxy = NULL;
} else if (ctx->use_proxy == 2) {
// WebSocket