This should be checked in common, not in dbi library

This commit is contained in:
Piotr Przybylski 2011-07-27 17:25:20 +02:00
parent 2141b5fe81
commit 69ac509584
3 changed files with 5 additions and 9 deletions

View File

@ -899,6 +899,11 @@ if (! defined('PMA_MINIMUM_COMMON')) {
unset($login_without_password_is_forbidden); //Clean up after you!
}
// if using TCP socket is not needed
if (strtolower($cfg['Server']['connect_type']) == 'tcp') {
$cfg['Server']['socket'] = '';
}
// Try to connect MySQL with the control user profile (will be used to
// get the privileges list for the current user but the true user link
// must be open after this one so it would be default one for all the

View File

@ -72,10 +72,6 @@ function PMA_DBI_connect($user, $password, $is_controluser = false, $server = nu
: ':' . $cfg['Server']['socket'];
}
if (strtolower($cfg['Server']['connect_type']) == 'tcp') {
$cfg['Server']['socket'] = '';
}
$client_flags = 0;
// always use CLIENT_LOCAL_FILES as defined in mysql_com.h

View File

@ -74,11 +74,6 @@ function PMA_DBI_connect($user, $password, $is_controluser = false, $server = nu
: $GLOBALS['cfg']['Server']['socket'];
}
if (strtolower($GLOBALS['cfg']['Server']['connect_type']) == 'tcp') {
$GLOBALS['cfg']['Server']['socket'] = '';
}
// NULL enables connection to the default socket
$link = mysqli_init();