aboutsummaryrefslogtreecommitdiff
path: root/ssl/bio_ssl.c
diff options
context:
space:
mode:
authorMatt Caswell <matt@openssl.org>2016-04-26 17:52:21 +0100
committerMatt Caswell <matt@openssl.org>2016-04-27 09:20:11 +0100
commitdbd5c34f18d9119cfdeca439eb7aac28117f53d4 (patch)
tree72140459905ce83feb617eb999e8121a89e8bd88 /ssl/bio_ssl.c
parent97b04399b6b20d59ce4898def02011ee80914638 (diff)
downloadopenssl-dbd5c34f18d9119cfdeca439eb7aac28117f53d4.zip
openssl-dbd5c34f18d9119cfdeca439eb7aac28117f53d4.tar.gz
openssl-dbd5c34f18d9119cfdeca439eb7aac28117f53d4.tar.bz2
Fix BIO_CTRL_DUP for an SSL BIO
The variables in the BIO weren't being duplicated properly. Reviewed-by: Richard Levitte <levitte@openssl.org> Reviewed-by: Viktor Dukhovni <viktor@openssl.org>
Diffstat (limited to 'ssl/bio_ssl.c')
-rw-r--r--ssl/bio_ssl.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/ssl/bio_ssl.c b/ssl/bio_ssl.c
index e3deebc..4cbfb3c 100644
--- a/ssl/bio_ssl.c
+++ b/ssl/bio_ssl.c
@@ -424,10 +424,11 @@ static long ssl_ctrl(BIO *b, int cmd, long num, void *ptr)
dbs = BIO_get_data(dbio);
SSL_free(dbs->ssl);
dbs->ssl = SSL_dup(ssl);
- dbs->renegotiate_count = dbs->renegotiate_count;
- dbs->byte_count = dbs->byte_count;
- dbs->renegotiate_timeout = dbs->renegotiate_timeout;
- dbs->last_time = dbs->last_time;
+ dbs->num_renegotiates = bs->num_renegotiates;
+ dbs->renegotiate_count = bs->renegotiate_count;
+ dbs->byte_count = bs->byte_count;
+ dbs->renegotiate_timeout = bs->renegotiate_timeout;
+ dbs->last_time = bs->last_time;
ret = (dbs->ssl != NULL);
break;
case BIO_C_GET_FD: