From 2ce4223e375bab68b3d6fc575c0d0871c4b63c05 Mon Sep 17 00:00:00 2001 From: Luca Deri Date: Mon, 21 Oct 2019 15:36:38 +0200 Subject: [PATCH] Silenced warning message --- src/lib/protocols/tls.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/lib/protocols/tls.c b/src/lib/protocols/tls.c index cb4f7ac0563..8511241a677 100644 --- a/src/lib/protocols/tls.c +++ b/src/lib/protocols/tls.c @@ -820,9 +820,12 @@ int getSSCertificateFingerprint(struct ndpi_detection_module_struct *ndpi_struct if(flow->l4.tcp.tls_srv_cert_fingerprint_ctx == NULL) flow->l4.tcp.tls_srv_cert_fingerprint_ctx = (void*)ndpi_malloc(sizeof(SHA1_CTX)); - else - printf("[TLS] Internal error: double allocation\n:"); - + else { +#ifdef DEBUG_TLS + printf("[TLS] Internal error: double allocation\n"); +#endif + } + if(flow->l4.tcp.tls_srv_cert_fingerprint_ctx) { SHA1Init(flow->l4.tcp.tls_srv_cert_fingerprint_ctx); flow->l4.tcp.tls_srv_cert_fingerprint_found = 1;