Changeset

3370:7c87af1c9a68

certmanager: Fix to handle the case of no SSL configuration at all
author Matthew Wild <mwild1@gmail.com>
date Wed, 14 Jul 2010 16:24:15 +0100
parents 3369:9a96969d4670
children 3372:395f692b3182
files core/certmanager.lua
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/core/certmanager.lua	Thu Jul 15 11:28:31 2010 +0500
+++ b/core/certmanager.lua	Wed Jul 14 16:24:15 2010 +0100
@@ -23,9 +23,9 @@
 local default_capath = "/etc/ssl/certs";
 
 function create_context(host, mode, config)
-	if not ssl then return nil; end
-	
 	local user_ssl_config = config and config.core.ssl or default_ssl_config;
+
+	if not(ssl and user_ssl_config) then return nil; end
 	
 	local ssl_config = {
 		mode = mode;