From fa928897a647079070fabeb224bd9500f1d8d4fc Mon Sep 17 00:00:00 2001 From: bcook <> Date: Mon, 18 Jan 2016 16:15:14 +0000 Subject: Call BIO_sock_init() from tls_init() to ensure sockets are enabled on Windows. This is of course a no-op on other platforms. Noted by equalsraf from github. --- src/lib/libtls/tls.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/lib') diff --git a/src/lib/libtls/tls.c b/src/lib/libtls/tls.c index 0a7c958369..5ca555027f 100644 --- a/src/lib/libtls/tls.c +++ b/src/lib/libtls/tls.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls.c,v 1.34 2015/10/07 23:25:45 beck Exp $ */ +/* $OpenBSD: tls.c,v 1.35 2016/01/18 16:15:14 bcook Exp $ */ /* * Copyright (c) 2014 Joel Sing * @@ -44,6 +44,9 @@ tls_init(void) SSL_load_error_strings(); SSL_library_init(); + if (BIO_sock_init() != 1) + return (-1); + if ((tls_config_default = tls_config_new()) == NULL) return (-1); -- cgit v1.2.3-55-g6feb