Don't reach into SSL in BIO_f_ssl.
We can implement this with the SSL stack's public API fine. Change-Id: Ia95c9174d7b850b7fed89046d3c351c970855cf3 Reviewed-on: https://boringssl-review.googlesource.com/13565 Commit-Queue: David Benjamin <davidben@google.com> Commit-Queue: Adam Langley <agl@google.com> Reviewed-by: Adam Langley <agl@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
This commit is contained in:
parent
5fa2cdf1ed
commit
3c0e037756
@ -107,14 +107,14 @@ static long ssl_ctrl(BIO *bio, int cmd, long num, void *ptr) {
|
|||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
case BIO_CTRL_WPENDING:
|
case BIO_CTRL_WPENDING:
|
||||||
return BIO_ctrl(ssl->wbio, cmd, num, ptr);
|
return BIO_ctrl(SSL_get_wbio(ssl), cmd, num, ptr);
|
||||||
|
|
||||||
case BIO_CTRL_PENDING:
|
case BIO_CTRL_PENDING:
|
||||||
return SSL_pending(ssl);
|
return SSL_pending(ssl);
|
||||||
|
|
||||||
case BIO_CTRL_FLUSH: {
|
case BIO_CTRL_FLUSH: {
|
||||||
BIO_clear_retry_flags(bio);
|
BIO_clear_retry_flags(bio);
|
||||||
long ret = BIO_ctrl(ssl->wbio, cmd, num, ptr);
|
long ret = BIO_ctrl(SSL_get_wbio(ssl), cmd, num, ptr);
|
||||||
BIO_copy_next_retry(bio);
|
BIO_copy_next_retry(bio);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
@ -125,7 +125,7 @@ static long ssl_ctrl(BIO *bio, int cmd, long num, void *ptr) {
|
|||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return BIO_ctrl(ssl->rbio, cmd, num, ptr);
|
return BIO_ctrl(SSL_get_rbio(ssl), cmd, num, ptr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -159,7 +159,7 @@ static long ssl_callback_ctrl(BIO *bio, int cmd, bio_info_cb fp) {
|
|||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return BIO_callback_ctrl(ssl->rbio, cmd, fp);
|
return BIO_callback_ctrl(SSL_get_rbio(ssl), cmd, fp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user