bug #1406499, A username containing an hyphen cannot create a db

This commit is contained in:
Marc Delisle
2006-01-16 17:30:27 +00:00
parent 258d8bf84c
commit 424bb0a12f
2 changed files with 7 additions and 1 deletions

View File

@@ -158,7 +158,7 @@ if (PMA_MYSQL_INT_VERSION >= 40102) {
if (!$rs_usr) {
// OK, now we'd have to guess the user's hostname, but we
// only try out the 'username'@'%' case.
$rs_usr = PMA_DBI_try_query('SHOW GRANTS FOR ' . $mysql_cur_user . ';', $controllink, PMA_DBI_QUERY_STORE);
$rs_usr = PMA_DBI_try_query('SHOW GRANTS FOR ' . PMA_convert_using(PMA_sqlAddslashes($mysql_cur_user), 'quoted') . ';', $controllink, PMA_DBI_QUERY_STORE);
}
unset($local_query);
if ($rs_usr) {