diff options
author | Holger Weiss <holger@zedat.fu-berlin.de> | 2016-11-18 11:51:12 +0100 |
---|---|---|
committer | Holger Weiss <holger@zedat.fu-berlin.de> | 2016-11-18 11:51:12 +0100 |
commit | 303acfc64f2f656729bde803a410a10a80a76b40 (patch) | |
tree | 9bcc6015490531921ad5794ac55382a3a0aa96ee /plugins/check_smtp.c | |
parent | 1723a3c7610cc43438c51d1e5fed43e15099a60e (diff) | |
parent | fe1c4bb0e5ea3632d608a6b8b7e51d580856d833 (diff) | |
download | monitoring-plugins-303acfc64f2f656729bde803a410a10a80a76b40.tar.gz |
Merge remote-tracking branch 'monitoring-plugins/pr/1443'
* monitoring-plugins/pr/1443:
add openssl 1.1 support
Diffstat (limited to 'plugins/check_smtp.c')
-rw-r--r-- | plugins/check_smtp.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/plugins/check_smtp.c b/plugins/check_smtp.c index 05e81f2c..587a7245 100644 --- a/plugins/check_smtp.c +++ b/plugins/check_smtp.c @@ -235,8 +235,8 @@ main (int argc, char **argv) result = np_net_ssl_init(sd); if(result != STATE_OK) { printf (_("CRITICAL - Cannot create SSL context.\n")); - np_net_ssl_cleanup(); close(sd); + np_net_ssl_cleanup(); return STATE_CRITICAL; } else { ssl_established = 1; @@ -760,10 +760,12 @@ recvlines(char *buf, size_t bufsize) int my_close (void) { + int result; + result = close(sd); #ifdef HAVE_SSL - np_net_ssl_cleanup(); + np_net_ssl_cleanup(); #endif - return close(sd); + return result; } |