mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-03-05 02:49:01 +00:00
MINOR: ssl: free ctx when libssl doesn't support NPN
The previous fixda95fd90
("BUILD/MINOR: ssl: fix build with non-alpn/ non-npn libssl") does fix the build in old OpenSSL release, but I overlooked that the ctx is only freed when NPN is supported. Fix this by moving the #endif to the proper place (this was broken inc7566001
("MINOR: server: Add "alpn" and "npn" keywords")).
This commit is contained in:
parent
7f0165e399
commit
7706b85e0c
@ -4846,9 +4846,9 @@ void ssl_sock_free_srv_ctx(struct server *srv)
|
||||
#ifdef OPENSSL_NPN_NEGOTIATED
|
||||
if (srv->ssl_ctx.npn_str)
|
||||
free(srv->ssl_ctx.npn_str);
|
||||
#endif
|
||||
if (srv->ssl_ctx.ctx)
|
||||
SSL_CTX_free(srv->ssl_ctx.ctx);
|
||||
#endif
|
||||
}
|
||||
|
||||
/* Walks down the two trees in bind_conf and frees all the certs. The pointer may
|
||||
|
Loading…
Reference in New Issue
Block a user