Module: kamailio
Branch: master
Commit: 294841104b02c98c826a629c2e4a499c1a3d5522
URL:
https://github.com/kamailio/kamailio/commit/294841104b02c98c826a629c2e4a499…
Author: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Committer: Victor Seva <linuxmaniac(a)torreviejawireless.org>
Date: 2024-11-19T17:26:08+01:00
tls: clang-format [skip ci]
---
Modified: src/modules/tls/tls_init.c
Modified: src/modules/tls/tls_mod.c
---
Diff:
https://github.com/kamailio/kamailio/commit/294841104b02c98c826a629c2e4a499…
Patch:
https://github.com/kamailio/kamailio/commit/294841104b02c98c826a629c2e4a499…
---
diff --git a/src/modules/tls/tls_init.c b/src/modules/tls/tls_init.c
index 6992d4a65e2..77af27d8d32 100644
--- a/src/modules/tls/tls_init.c
+++ b/src/modules/tls/tls_init.c
@@ -741,41 +741,41 @@ int tls_pre_init(void)
*/
long tls_h_mod_randctx(void *param)
{
- do {
- OSSL_LIB_CTX *osslglobal = NULL;
- EVP_RAND_CTX *randctx = NULL;
-
- LM_DBG("enabling locking for rand ctx\n");
-
- osslglobal = OSSL_LIB_CTX_get0_global_default();
- if(osslglobal == NULL) {
- LM_ERR("failed to get lib ssl global ctx\n");
- return -1L;
- }
-
- randctx = RAND_get0_primary(osslglobal);
- if(randctx == NULL) {
- LM_ERR("primary rand ctx is null\n");
- return -1L;
- }
- EVP_RAND_enable_locking(randctx);
-
- randctx = RAND_get0_public(osslglobal);
- if(randctx == NULL) {
- LM_ERR("public rand ctx is null\n");
- return -1L;
- }
- EVP_RAND_enable_locking(randctx);
-
- randctx = RAND_get0_private(osslglobal);
- if(randctx == NULL) {
- LM_ERR("private rand ctx is null\n");
- return -1L;
- }
- EVP_RAND_enable_locking(randctx);
- } while(0);
-
- return 0L;
+ do {
+ OSSL_LIB_CTX *osslglobal = NULL;
+ EVP_RAND_CTX *randctx = NULL;
+
+ LM_DBG("enabling locking for rand ctx\n");
+
+ osslglobal = OSSL_LIB_CTX_get0_global_default();
+ if(osslglobal == NULL) {
+ LM_ERR("failed to get lib ssl global ctx\n");
+ return -1L;
+ }
+
+ randctx = RAND_get0_primary(osslglobal);
+ if(randctx == NULL) {
+ LM_ERR("primary rand ctx is null\n");
+ return -1L;
+ }
+ EVP_RAND_enable_locking(randctx);
+
+ randctx = RAND_get0_public(osslglobal);
+ if(randctx == NULL) {
+ LM_ERR("public rand ctx is null\n");
+ return -1L;
+ }
+ EVP_RAND_enable_locking(randctx);
+
+ randctx = RAND_get0_private(osslglobal);
+ if(randctx == NULL) {
+ LM_ERR("private rand ctx is null\n");
+ return -1L;
+ }
+ EVP_RAND_enable_locking(randctx);
+ } while(0);
+
+ return 0L;
}
#endif /* OPENSSL_VERSION_NUMBER */
diff --git a/src/modules/tls/tls_mod.c b/src/modules/tls/tls_mod.c
index b247b336900..b86cbe0a110 100644
--- a/src/modules/tls/tls_mod.c
+++ b/src/modules/tls/tls_mod.c
@@ -492,15 +492,17 @@ static int mod_init(void)
#if OPENSSL_VERSION_NUMBER < 0x030000000L
- LM_INFO("compiled with OpenSSL version: %08x\n",
(uint32_t)(OPENSSL_VERSION_NUMBER));
+ LM_INFO("compiled with OpenSSL version: %08x\n",
+ (uint32_t)(OPENSSL_VERSION_NUMBER));
#elif OPENSSL_VERSION_NUMBER >= 0x030000000L
- LM_INFO("compiled with OpenSSL version: %08x\n",
(uint32_t)(OPENSSL_VERSION_NUMBER));
+ LM_INFO("compiled with OpenSSL version: %08x\n",
+ (uint32_t)(OPENSSL_VERSION_NUMBER));
LM_INFO("compile-time OpenSSL library: %s\n", OPENSSL_VERSION_TEXT);
LM_INFO("run-time OpenSSL library: %s\n", OpenSSL_version(OPENSSL_VERSION));
if(EVP_default_properties_is_fips_enabled(NULL) == 1) {
LM_INFO("FIPS mode enabled in OpenSSL library\n");
- } else {
+ } else {
LM_DBG("FIPS mode not enabled in OpenSSL library\n");
}
#endif