Skip to content

Commit

Permalink
tls_mgm: add extra debugging in case mem function fail
Browse files Browse the repository at this point in the history
  • Loading branch information
razvancrainea committed Aug 16, 2016
1 parent a1242bd commit 9355818
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions modules/tls_mgm/tls_mgm.c
Expand Up @@ -1273,10 +1273,16 @@ static int mod_init(void){
* CRYPTO_malloc will set allow_customize in openssl to 0
*/
if (!CRYPTO_set_mem_functions(os_malloc, os_realloc, os_free)) {
void *(*m) (size_t);
void *(*r) (void *, size_t);
void (*f) (void *);
LM_ERR("unable to set the memory allocation functions\n");
LM_ERR("NOTE: check if you have openssl 1.0.1e-fips, as this "
"version is known to be broken; if so, you need to upgrade or "
"downgrade to a different openssl version !!\n");
CRYPTO_get_mem_functions(&m, &r, &f);
LM_ERR("extra: malloc=%p/%p realloc=%p/%p free=%p/%p\n",
os_malloc, m, os_realloc, r, os_free, f);
return -1;
}

Expand Down

0 comments on commit 9355818

Please sign in to comment.