|
@@ -311,16 +311,17 @@ main (int argc, char **argv)
|
|
|
printf("%s", buffer);
|
|
printf("%s", buffer);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-# ifdef USE_OPENSSL
|
|
|
|
|
- if ( check_cert ) {
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+#endif
|
|
|
|
|
+
|
|
|
|
|
+#ifdef USE_OPENSSL
|
|
|
|
|
+ if ( (use_ssl || use_starttls) && check_cert ) {
|
|
|
result = np_net_ssl_check_cert(days_till_exp_warn, days_till_exp_crit);
|
|
result = np_net_ssl_check_cert(days_till_exp_warn, days_till_exp_crit);
|
|
|
smtp_quit();
|
|
smtp_quit();
|
|
|
my_close();
|
|
my_close();
|
|
|
return result;
|
|
return result;
|
|
|
}
|
|
}
|
|
|
-# endif /* USE_OPENSSL */
|
|
|
|
|
- }
|
|
|
|
|
-#endif
|
|
|
|
|
|
|
+#endif /* USE_OPENSSL */
|
|
|
|
|
|
|
|
if (send_mail_from) {
|
|
if (send_mail_from) {
|
|
|
my_send(cmd_str, strlen(cmd_str));
|
|
my_send(cmd_str, strlen(cmd_str));
|