avoid going back to login page on slave configuration
This commit is contained in:
@@ -46,7 +46,7 @@ function PMA_DBI_real_connect($server, $user, $password, $client_flags, $persist
|
||||
* @param string $password mysql user password
|
||||
* @param boolean $is_controluser
|
||||
* @param array $server host/port/socket/persistant
|
||||
* @param boolean $auxiliary_connection (if fails, don't go back to login)
|
||||
* @param boolean $auxiliary_connection (when true, don't go back to login if connection fails)
|
||||
* @return mixed false on error or a mysqli object on success
|
||||
*/
|
||||
function PMA_DBI_connect($user, $password, $is_controluser = false, $server = null, $auxiliary_connection = false)
|
||||
|
@@ -61,7 +61,7 @@ if (! defined('MYSQLI_TYPE_BIT')) {
|
||||
* @param string $password mysql user password
|
||||
* @param boolean $is_controluser
|
||||
* @param array $server host/port/socket
|
||||
* @param boolean $auxiliary_connection (if fails, don't go back to login)
|
||||
* @param boolean $auxiliary_connection (when true, don't go back to login if connection fails)
|
||||
* @return mixed false on error or a mysqli object on success
|
||||
*/
|
||||
function PMA_DBI_connect($user, $password, $is_controluser = false, $server = null, $auxiliary_connection = false)
|
||||
|
@@ -200,7 +200,9 @@ function PMA_replication_connect_to_master($user, $password, $host = null, $port
|
||||
$server["port"] = $port;
|
||||
$server["socket"] = $socket;
|
||||
|
||||
return PMA_DBI_connect($user, $password, false, $server);
|
||||
// 5th parameter set to true means that it's an auxiliary connection
|
||||
// and we must not go back to login page if it fails
|
||||
return PMA_DBI_connect($user, $password, false, $server, true);
|
||||
}
|
||||
/**
|
||||
* @param $link - mysql link
|
||||
|
Reference in New Issue
Block a user