aboutsummaryrefslogtreecommitdiff
path: root/plugins/check_http.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/check_http.c')
-rw-r--r--plugins/check_http.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/plugins/check_http.c b/plugins/check_http.c
index d47f5ce6..294866b0 100644
--- a/plugins/check_http.c
+++ b/plugins/check_http.c
@@ -801,16 +801,15 @@ check_http (void)
if (connect_SSL () != OK) {
die (STATE_CRITICAL, _("Unable to open TCP socket\n"));
}
-#ifdef USE_OPENSSL
+# ifdef USE_OPENSSL
if ((server_cert = SSL_get_peer_certificate (ssl)) != NULL) {
X509_free (server_cert);
}
-#endif
else {
printf (_("CRITICAL - Cannot retrieve server certificate.\n"));
return STATE_CRITICAL;
}
-
+# endif /* USE_OPENSSL */
}
else {
#endif