Optimization - do not call "mysql_numrows", "mysql_results" and "mysql_fetch_array" on invalid queries

This commit is contained in:
Loïc Chapeaux
2002-05-01 12:03:21 +00:00
parent 2ac7b84a33
commit 2e28add87b
13 changed files with 36 additions and 39 deletions

View File

@@ -228,7 +228,7 @@ if ($server > 0) {
$db_to_create = '';
break;
} // end if
elseif (ereg($re . '%|_', $show_grants_dbname) || !mysql_select_db($show_grants_dbname, $userlink) && @mysql_errno() != 1044) {
else if (ereg($re . '%|_', $show_grants_dbname) || !mysql_select_db($show_grants_dbname, $userlink) && @mysql_errno() != 1044) {
$show_grants_dbname = ereg_replace($re . '%', '\\1...', ereg_replace($re . '_', '\\1?', $show_grants_dbname));
$db_to_create = $show_grants_dbname;
$is_create_priv = TRUE;