mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-11-28 06:11:32 +01:00
BUILD/MINOR: ssl: de-constify "ciphers" to avoid a warning on openssl-0.9.8
When building on openssl-0.9.8, since commit 23d5d37 ("MINOR: ssl: use
SSL_get_ciphers() instead of directly accessing the cipher list.") we get
the following warning :
src/ssl_sock.c: In function 'ssl_sock_prepare_ctx':
src/ssl_sock.c:1592: warning: passing argument 1 of 'SSL_CIPHER_description' discards qualifiers from pointer target type
This is because the openssl API has changed between 0.9.8 and 1.0.1 :
0.9.8: char *SSL_CIPHER_description(SSL_CIPHER *,char *buf,int size);
1.0.1: char *SSL_CIPHER_description(const SSL_CIPHER *,char *buf,int size);
So let's remove the "const" type qualifier to satisfy both versions.
Note that the fix above was backported to 1.5, so this one should as well.
This commit is contained in:
parent
317e1c4f1e
commit
a616ba6f5f
@ -1479,7 +1479,7 @@ int ssl_sock_prepare_ctx(struct bind_conf *bind_conf, SSL_CTX *ctx, struct proxy
|
||||
SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER |
|
||||
SSL_MODE_RELEASE_BUFFERS;
|
||||
STACK_OF(SSL_CIPHER) * ciphers = NULL;
|
||||
SSL_CIPHER const * cipher = NULL;
|
||||
SSL_CIPHER * cipher = NULL;
|
||||
char cipher_description[128];
|
||||
/* The description of ciphers using an Ephemeral Diffie Hellman key exchange
|
||||
contains " Kx=DH " or " Kx=DH(". Beware of " Kx=DH/",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user