Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Langley <agl@chromium.org>2014-07-16 03:26:34 +0400
committerAdam Langley <agl@google.com>2014-07-16 03:31:50 +0400
commit0cc81ff04f7364183f97ce2ca573a56fbfe3d156 (patch)
treefaef6e7bba0495d3f42098a4ad7af8108c32e64e /crypto/bio
parent449f16b947bf3df8a0151468d330918378ad8acb (diff)
Add functions for setting a BIO callback and arg.
These were omitted, but are needed by Chromium now. Change-Id: I17e1672674311c8dc2ede21539c82b8e2e50f376 Reviewed-on: https://boringssl-review.googlesource.com/1201 Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'crypto/bio')
-rw-r--r--crypto/bio/bio.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/crypto/bio/bio.c b/crypto/bio/bio.c
index d9f7f40d..11e4f65f 100644
--- a/crypto/bio/bio.c
+++ b/crypto/bio/bio.c
@@ -359,6 +359,18 @@ int BIO_set_close(BIO *bio, int close_flag) {
return BIO_ctrl(bio, BIO_CTRL_SET_CLOSE, close_flag, NULL);
}
+void BIO_set_callback(BIO *bio, bio_info_cb callback_func) {
+ bio->callback = callback_func;
+}
+
+void BIO_set_callback_arg(BIO *bio, char *arg) {
+ bio->cb_arg = arg;
+}
+
+char *BIO_get_callback_arg(const BIO *bio) {
+ return bio->cb_arg;
+}
+
BIO *BIO_push(BIO *bio, BIO *appended_bio) {
BIO *last_bio;