Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37765993
en ru br
ALT Linux repos
S:1.2-alt3

Group :: Text tools
RPM: getxbook

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

Patch: getxbook-openssl.patch
Download


diff --git a/getxbook/util.c b/getxbook/util.c
index d672c9e..5fbb77d 100644
--- getxbook/util.c
+++ getxbook/util.c
@@ -58,7 +58,12 @@ conn *dial(char *host, char *port, int ssl)
 	if(ssl) {
 		SSL_load_error_strings();
 		SSL_library_init();
-		if((sslcontext = SSL_CTX_new(TLSv1_2_client_method())) == NULL) {
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L)
+		sslcontext = SSL_CTX_new(TLSv1_2_client_method());
+#else
+		sslcontext = SSL_CTX_new(TLS_client_method());
+#endif
+		if(sslcontext == NULL) {
 			ERR_print_errors_fp(stderr);
 		}
 		if((c->sslhandle = SSL_new(sslcontext)) == NULL) {
 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin