From da157b7f662d884637be5c956ccfb7ec578a3795 Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Sun, 20 Aug 2017 17:35:19 +0000 Subject: remove a duplicate BIO_do_accept() call from an example; from Beat Bolli via OpenSSL commit 7a67a3ba Jan 18 23:49:43 2017 +0100 --- lib/libssl/man/BIO_f_ssl.3 | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/lib/libssl/man/BIO_f_ssl.3 b/lib/libssl/man/BIO_f_ssl.3 index ec3114db28d..5404b9c70fc 100644 --- a/lib/libssl/man/BIO_f_ssl.3 +++ b/lib/libssl/man/BIO_f_ssl.3 @@ -1,5 +1,6 @@ -.\" $OpenBSD: BIO_f_ssl.3,v 1.4 2017/04/10 16:11:50 schwarze Exp $ -.\" OpenSSL f672aee4 Feb 9 11:52:40 2016 -0500 +.\" $OpenBSD: BIO_f_ssl.3,v 1.5 2017/08/20 17:35:18 schwarze Exp $ +.\" OpenSSL BIO_f_ssl.pod e90fc053 Jul 15 09:39:45 2017 -0400 +.\" OpenSSL BIO_f_ssl.pod f672aee4 Feb 9 11:52:40 2016 -0500 .\" .\" This file was written by Dr. Stephen Henson . .\" Copyright (c) 2000, 2003, 2009, 2014-2016 The OpenSSL Project. @@ -49,7 +50,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: April 10 2017 $ +.Dd $Mdocdate: August 20 2017 $ .Dt BIO_F_SSL 3 .Os .Sh NAME @@ -493,20 +494,13 @@ BIO_set_accept_bios(acpt,sbio); out = BIO_new_fp(stdout, BIO_NOCLOSE); -/* Setup accept BIO */ +/* Wait for incoming connection */ if (BIO_do_accept(acpt) <= 0) { fprintf(stderr, "Error setting up accept BIO\en"); ERR_print_errors_fp(stderr); return 0; } -/* Now wait for incoming connection */ -if (BIO_do_accept(acpt) <= 0) { - fprintf(stderr, "Error in connection\en"); - ERR_print_errors_fp(stderr); - return 0; -} - /* We only want one connection so remove and free accept BIO */ sbio = BIO_pop(acpt); @@ -542,7 +536,7 @@ BIO_flush(sbio); BIO_free_all(sbio); .Ed -.Sh BUGS +.Sh HISTORY In OpenSSL versions before 1.0.0 the .Xr BIO_pop 3 call was handled incorrectly: -- cgit v1.2.3