Blame SOURCES/autofs-5.1.5-openssl-workaround.patch

304803
autofs-5.1.5 - openssl workaround
304803
304803
From: Ian Kent <raven@themaw.net>
304803
304803
Pre-open openssl libraries to prevent possible library unloads
304803
that could leave library static data undefined.
304803
304803
---
304803
 daemon/automount.c |   14 ++++++++++++++
304803
 1 file changed, 14 insertions(+)
304803
304803
--- autofs-5.0.7.orig/daemon/automount.c
304803
+++ autofs-5.0.7/daemon/automount.c
304803
@@ -2641,6 +2641,11 @@ int main(int argc, char *argv[])
304803
 		dh_tirpc = dlopen("libtirpc.so.1", RTLD_NOW);
304803
 #endif
304803
 
304803
+	void *dh_ossl10 = dlopen("libssl.so.10", RTLD_NOW);
304803
+	void *dh_crypto10 = dlopen("libcrypto.so.10", RTLD_NOW);
304803
+	void *dh_ossl6 = dlopen("libssl.so.6", RTLD_NOW);
304803
+	void *dh_crypto6 = dlopen("libcrypto.so.6", RTLD_NOW);
304803
+
304803
 	master_read = master_read_master(master_list, age, 0);
304803
 	if (!master_read) {
304803
 		/*
304803
@@ -2693,6 +2698,15 @@ int main(int argc, char *argv[])
304803
 	release_flag_file();
304803
 	macro_free_global_table();
304803
 
304803
+	if (dh_ossl10)
304803
+		dlclose(dh_ossl10);
304803
+	if (dh_crypto10)
304803
+		dlclose(dh_crypto10);
304803
+	if (dh_ossl6)
304803
+		dlclose(dh_ossl6);
304803
+	if (dh_crypto6)
304803
+		dlclose(dh_crypto6);
304803
+
304803
 #ifdef TIRPC_WORKAROUND
304803
 	if (dh_tirpc)
304803
 		dlclose(dh_tirpc);