diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2017-09-22 16:06:52 +0100 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2017-09-22 22:59:42 +0100 |
commit | 9e84a42db497e06a38f804b5acd09b6aa4f87db3 (patch) | |
tree | f540bd69b0d412561f4d71639704f1117bd6fc46 /ssl/ssl_lib.c | |
parent | 6d50589c0434a78733d40d3a0fd7cb97eef1cb94 (diff) |
Store groups as uint16_t
Instead of storing supported groups in on-the-wire format store
them as parsed uint16_t values. This simplifies handling of groups
as the values can be directly used instead of being converted.
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4406)
Diffstat (limited to 'ssl/ssl_lib.c')
-rw-r--r-- | ssl/ssl_lib.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 711846dc01..48ce7c179c 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -719,7 +719,8 @@ SSL *SSL_new(SSL_CTX *ctx) if (ctx->ext.supportedgroups) { s->ext.supportedgroups = OPENSSL_memdup(ctx->ext.supportedgroups, - ctx->ext.supportedgroups_len); + ctx->ext.supportedgroups_len + * sizeof(ctx->ext.supportedgroups)); if (!s->ext.supportedgroups) goto err; s->ext.supportedgroups_len = ctx->ext.supportedgroups_len; |