Parcourir la source

tls: warn if tls_threads_mode=1 and force value to 2

S-P Chan il y a 8 mois
Parent
commit
b5cb581bd8
1 fichiers modifiés avec 6 ajouts et 0 suppressions
  1. 6 0
      src/modules/tls/tls_mod.c

+ 6 - 0
src/modules/tls/tls_mod.c

@@ -408,6 +408,12 @@ static int mod_init(void)
 					"tls.so must be the first module loaded\n");
 		}
 	}
+
+	if(ksr_tls_threads_mode == KSR_TLS_THREADS_MTEMP) {
+		LM_WARN("tls_threads_mode=1 is invalid on kamailio version >= 6; "
+				"forcing tls_threads_mode=2\n");
+		ksr_tls_threads_mode = KSR_TLS_THREADS_MFORK;
+	}
 #endif /*  OPENSSL_VERSION_NUMBER*/
 
 	if(tls_disable) {