aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Holger Weiss <hweiss@users.sourceforge.net> 2007-06-01 17:06:33 +0000
committerGravatar Holger Weiss <hweiss@users.sourceforge.net> 2007-06-01 17:06:33 +0000
commitf747b865aa23e31c94ef350ab601485fea1a1a7e (patch)
tree4ec4db5eeed47ed03064a33a9165bd60b14b80d5
parentbad9e04c542d0cf07a14b843f0d38f78c2b0b03c (diff)
downloadmonitoring-plugins-f747b865aa23e31c94ef350ab601485fea1a1a7e.tar.gz
Save an entire CPU cycle if c points to NULL already.
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1725 f882894a-f735-0410-b71e-b25c423dba1c
-rw-r--r--plugins/sslutils.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/sslutils.c b/plugins/sslutils.c
index cf3c4032..84a1c8fc 100644
--- a/plugins/sslutils.c
+++ b/plugins/sslutils.c
@@ -70,8 +70,10 @@ void np_net_ssl_cleanup (){
if(s){
SSL_shutdown (s);
SSL_free (s);
- if(c) SSL_CTX_free (c);
- c=NULL;
+ if(c) {
+ SSL_CTX_free (c);
+ c=NULL;
+ }
s=NULL;
}
}