View | Details | Raw Unified | Return to bug 171196
Collapse All | Expand All

(-)nzbget/files/patch-TLS.cpp (+32 lines)
Line 0 Link Here
1
--- TLS.cpp.orig	2011-06-14 23:47:22.000000000 +0200
2
+++ TLS.cpp	2012-08-31 09:27:41.000000000 +0200
3
@@ -908,7 +908,7 @@
4
     char *buf;
5
     int bufsize;
6
     /* needed to get the DNS subjectAltNames: */
7
-    STACK *subj_alt_names;
8
+    STACK_OF(GENERAL_NAME) *subj_alt_names;
9
     int subj_alt_names_count;
10
     GENERAL_NAME *subj_alt_name;
11
     /* did we find a name matching hostname? */
12
@@ -960,7 +960,7 @@
13
     /* Try the DNS subjectAltNames. */
14
     match_found = 0;
15
     if ((subj_alt_names =
16
-		(STACK*)X509_get_ext_d2i(x509cert, NID_subject_alt_name, NULL, NULL)))
17
+		(STACK_OF(GENERAL_NAME) *)X509_get_ext_d2i(x509cert, NID_subject_alt_name, NULL, NULL)))
18
     {
19
 	subj_alt_names_count = sk_GENERAL_NAME_num(subj_alt_names);
20
 	for (i = 0; i < subj_alt_names_count; i++) 
21
@@ -1105,7 +1105,11 @@
22
 
23
 #ifdef HAVE_OPENSSL
24
     
25
+    #if OPENSSL_VERSION_NUMBER >= 0x10000000L
26
+    const SSL_METHOD *ssl_method = NULL;
27
+    #else
28
     SSL_METHOD *ssl_method = NULL;
29
+    #endif
30
     
31
     ssl_method = force_sslv3 ? SSLv3_client_method() : SSLv23_client_method();
32
     if (!ssl_method)

Return to bug 171196