diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/libtls/tls_bio_cb.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/libtls/tls_bio_cb.c b/src/lib/libtls/tls_bio_cb.c index 28eba24c91..813d98d990 100644 --- a/src/lib/libtls/tls_bio_cb.c +++ b/src/lib/libtls/tls_bio_cb.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: tls_bio_cb.c,v 1.14 2016/11/04 15:45:55 jsing Exp $ */ | 1 | /* $OpenBSD: tls_bio_cb.c,v 1.15 2017/01/12 15:58:56 jsing Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2016 Tobias Pape <tobias@netshed.de> | 3 | * Copyright (c) 2016 Tobias Pape <tobias@netshed.de> |
4 | * | 4 | * |
@@ -176,8 +176,10 @@ tls_get_new_cb_bio(struct tls *ctx) | |||
176 | struct bio_cb *bcb; | 176 | struct bio_cb *bcb; |
177 | BIO *bio; | 177 | BIO *bio; |
178 | 178 | ||
179 | if (ctx->read_cb == NULL || ctx->write_cb == NULL) | 179 | if (ctx->read_cb == NULL || ctx->write_cb == NULL) { |
180 | tls_set_errorx(ctx, "no callbacks registered"); | 180 | tls_set_errorx(ctx, "no callbacks registered"); |
181 | return (NULL); | ||
182 | } | ||
181 | 183 | ||
182 | if ((bio = BIO_new(bio_s_cb())) == NULL) { | 184 | if ((bio = BIO_new(bio_s_cb())) == NULL) { |
183 | tls_set_errorx(ctx, "failed to create callback i/o"); | 185 | tls_set_errorx(ctx, "failed to create callback i/o"); |