summaryrefslogtreecommitdiffstats
path: root/ssl
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2014-01-27 14:30:29 +0000
committerDr. Stephen Henson <steve@openssl.org>2014-01-27 14:32:44 +0000
commit9f1979b94a7b21dd1830e9118bf78ccd4285c25b (patch)
treeeee11a5ae203873127ad9146f8dedd8958f2353e /ssl
parent3fcf327e26f05b73f92e0e19946b888721945bc1 (diff)
New function to set compression methods so they can be safely freed.
(cherry picked from commit cbb67448277232c8403f96edad4931c4203e7746)
Diffstat (limited to 'ssl')
-rw-r--r--ssl/ssl.h1
-rw-r--r--ssl/ssl_ciph.c5
2 files changed, 6 insertions, 0 deletions
diff --git a/ssl/ssl.h b/ssl/ssl.h
index 6ac4e92216..1505816d34 100644
--- a/ssl/ssl.h
+++ b/ssl/ssl.h
@@ -2440,6 +2440,7 @@ const COMP_METHOD *SSL_get_current_compression(SSL *s);
const COMP_METHOD *SSL_get_current_expansion(SSL *s);
const char *SSL_COMP_get_name(const COMP_METHOD *comp);
STACK_OF(SSL_COMP) *SSL_COMP_get_compression_methods(void);
+void SSL_COMP_set0_compression_methods(STACK_OF(SSL_COMP) *meths);
int SSL_COMP_add_compression_method(int id,COMP_METHOD *cm);
#else
const void *SSL_get_current_compression(SSL *s);
diff --git a/ssl/ssl_ciph.c b/ssl/ssl_ciph.c
index 22047c3e41..33bbfa2810 100644
--- a/ssl/ssl_ciph.c
+++ b/ssl/ssl_ciph.c
@@ -1862,6 +1862,11 @@ STACK_OF(SSL_COMP) *SSL_COMP_get_compression_methods(void)
return(ssl_comp_methods);
}
+void SSL_COMP_set0_compression_methods(STACK_OF(SSL_COMP) *meths)
+ {
+ ssl_comp_methods = meths;
+ }
+
int SSL_COMP_add_compression_method(int id, COMP_METHOD *cm)
{
SSL_COMP *comp;