diff options
author | Holger Weiss <hweiss@users.sourceforge.net> | 2007-06-01 16:42:07 +0000 |
---|---|---|
committer | Holger Weiss <hweiss@users.sourceforge.net> | 2007-06-01 16:42:07 +0000 |
commit | bad9e04c542d0cf07a14b843f0d38f78c2b0b03c (patch) | |
tree | 688a9716f39fe419ae4d4aac443edbb1819e3d99 /plugins/sslutils.c | |
parent | 716ff400f04bd053a1bba0affd773b03f284baad (diff) | |
download | monitoring-plugins-bad9e04c542d0cf07a14b843f0d38f78c2b0b03c.tar.gz |
Set the pointers to the SSL and SSL_CTX objects back to NULL after
freeing them in np_net_ssl_cleanup(). This fixes a check_http segfault
if an SSL site redirects to a non-SSL one (reported by Aravind Gottipati
via IRC).
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1724 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins/sslutils.c')
-rw-r--r-- | plugins/sslutils.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/sslutils.c b/plugins/sslutils.c index 09d58b0f..cf3c4032 100644 --- a/plugins/sslutils.c +++ b/plugins/sslutils.c | |||
@@ -71,6 +71,8 @@ void np_net_ssl_cleanup (){ | |||
71 | SSL_shutdown (s); | 71 | SSL_shutdown (s); |
72 | SSL_free (s); | 72 | SSL_free (s); |
73 | if(c) SSL_CTX_free (c); | 73 | if(c) SSL_CTX_free (c); |
74 | c=NULL; | ||
75 | s=NULL; | ||
74 | } | 76 | } |
75 | } | 77 | } |
76 | 78 | ||