Disable compression for SSL socket,
it is a waste of CPU when using compression extensions.
diff --git a/lib/libwebsockets.c b/lib/libwebsockets.c
index 18c780b..302dab3 100644
--- a/lib/libwebsockets.c
+++ b/lib/libwebsockets.c
@@ -2729,6 +2729,8 @@
return NULL;
}
+ SSL_CTX_set_options(context->ssl_ctx, SSL_OP_NO_COMPRESSION);
+
/* client context */
if (port == CONTEXT_PORT_NO_LISTEN) {
@@ -2746,6 +2748,8 @@
return NULL;
}
+ SSL_CTX_set_options(context->ssl_client_ctx, SSL_OP_NO_COMPRESSION);
+
/* openssl init for cert verification (for client sockets) */
if (!ssl_ca_filepath) {
if (!SSL_CTX_load_verify_locations(