bug #3026400 [PHP] ereg functions are deprecated

This commit is contained in:
Marc Delisle
2010-07-08 07:49:11 -04:00
parent 104b0ee99a
commit 20d4c3a894
3 changed files with 16 additions and 15 deletions

View File

@@ -349,26 +349,26 @@ foreach ($tables as $keyname => $each_table) {
$ignored = false;
$do = false;
if ($server_slave_status) {
////////////////////////////////////////////////////////////////
if ((strlen(array_search($truename, $server_slave_Do_Table)) > 0)
|| (strlen(array_search($db, $server_slave_Do_DB))>0)
|| (count($server_slave_Do_DB)==1 && count($server_slave_Ignore_DB)==1)
|| (strlen(array_search($db, $server_slave_Do_DB)) > 0)
|| (count($server_slave_Do_DB) == 1 && count($server_slave_Ignore_DB) == 1)
) {
$do = true;
}
foreach ($server_slave_Wild_Do_Table as $table) {
if (($db == PMA_replication_strout($table)) && (ereg("^".substr(PMA_replication_strout($table, true), 0, strlen(PMA_replication_strout($table, true))-1), $truename)))
if (($db == PMA_replication_strout($table)) && (preg_match("@^" . substr(PMA_replication_strout($table, true), 0, strlen(PMA_replication_strout($table, true)) - 1) . "@", $truename)))
$do = true;
}
////////////////////////////////////////////////////////////////////
if ((strlen(array_search($truename, $server_slave_Ignore_Table))>0) || (strlen(array_search($db, $server_slave_Ignore_DB))>0)) {
if ((strlen(array_search($truename, $server_slave_Ignore_Table)) > 0) || (strlen(array_search($db, $server_slave_Ignore_DB)) > 0)) {
$ignored = true;
}
foreach ($server_slave_Wild_Ignore_Table as $table) {
if (($db == PMA_replication_strout($table)) && (ereg("^".substr(PMA_replication_strout($table, true), 0, strlen(PMA_replication_strout($table, true))-1), $truename)))
if (($db == PMA_replication_strout($table)) && (preg_match("@^" . substr(PMA_replication_strout($table, true), 0, strlen(PMA_replication_strout($table, true)) - 1) . "@", $truename)))
$ignored = true;
}
}/* elseif ($server_master_status) {