From e618359d4fc6587221f96ce284c872928d38056c Mon Sep 17 00:00:00 2001 From: daren-qterics Date: Sat, 10 Dec 2016 08:55:18 +0800 Subject: [PATCH] ssl destroy: change ordering of ssl destroy to later than vhost destroy https://github.com/warmcat/libwebsockets/issues/711 --- lib/context.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/context.c b/lib/context.c index 30883b74..bea95efd 100644 --- a/lib/context.c +++ b/lib/context.c @@ -891,7 +891,6 @@ lws_context_destroy(struct lws_context *context) lws_free(pt->http_header_data); } lws_plat_context_early_destroy(context); - lws_ssl_context_destroy(context); if (context->pt[0].fds) lws_free_set_NULL(context->pt[0].fds); @@ -935,6 +934,7 @@ lws_context_destroy(struct lws_context *context) vh = vh1; } + lws_ssl_context_destroy(context); lws_plat_context_late_destroy(context); lws_free(context);