From 41d3dedd5d09668c3be950ede9d1068e00c4ca95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Chapeaux?= Date: Sat, 15 Dec 2001 09:12:33 +0000 Subject: [PATCH] * ensure 'enable_dl' is set before using it; * ensured compatibility with old configuration files for the authentication mode. --- libraries/common.lib.php3 | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/libraries/common.lib.php3 b/libraries/common.lib.php3 index 79f7d8349..70be3b8dd 100644 --- a/libraries/common.lib.php3 +++ b/libraries/common.lib.php3 @@ -142,7 +142,7 @@ if (!defined('PMA_COMMON_LIB_INCLUDED')){ * Loads the mysql extensions if it is not loaded yet * staybyte - 26. June 2001 */ - if (((PMA_PHP_INT_VERSION >= 40000 && !@ini_get('safe_mode')) + if (((PMA_PHP_INT_VERSION >= 40000 && !@ini_get('safe_mode') && @ini_get('enable_dl')) || (PMA_PHP_INT_VERSION > 30009 && !@get_cfg_var('safe_mode'))) && @function_exists('dl')) { if (PMA_PHP_INT_VERSION < 40000) { @@ -319,6 +319,13 @@ if (!defined('PMA_COMMON_LIB_INCLUDED')){ ? '' : ':' . $cfgServer['socket']; + // Ensures compatibility with old config files + if (!isset($cfgServer['auth_type'])) { + $cfgServer['auth_type'] = (isset($cfgServer['adv_auth']) && $cfgServer['adv_auth']) + ? 'http' + : 'config'; + } + // Gets the authentication library that fits the cfgServer settings // and run authentication include('./libraries/auth/' . $cfgServer['auth_type'] . '.auth.lib.php3');