File links-sni.patch of Package links

---
 connect.c |    8 ++++++++
 1 file changed, 8 insertions(+)

Index: links-2.8/connect.c
===================================================================
--- links-2.8.orig/connect.c	2013-10-02 21:02:00.000000000 +0100
+++ links-2.8/connect.c	2013-10-02 21:02:14.000000000 +0100
@@ -587,6 +587,14 @@ static void connected(struct connection
 		if (!c->ssl) {
 			goto ssl_error;
 		}
+
+#if OPENSSL_VERSION_NUMBER >= 0x0090806fL && !defined(OPENSSL_NO_TLSEXT)
+        unsigned char *server_hostname = get_host_name(c->url);
+        if(server_hostname)
+            SSL_set_tlsext_host_name(c->ssl, server_hostname);
+
+        mem_free(server_hostname);
+#endif
 		SSL_set_fd(c->ssl, *b->sock);
 		switch ((ret2 = SSL_get_error(c->ssl, ret1 = SSL_connect(c->ssl)))) {
 			case SSL_ERROR_WANT_READ:
openSUSE Build Service is sponsored by