On enleve le test de caractères pour pouvoir quand meme supprimer les bases qui sont pas bien nommés

Closes: #635
This commit is contained in:
Nahuel Angelinetti 2006-07-07 13:03:47 +00:00
parent 6457588a56
commit e47071fc20
1 changed files with 2 additions and 5 deletions

View File

@ -173,11 +173,8 @@ class m_mysql {
function del_db($dbn) {
global $db,$err,$mem,$cuid;
$err->log("mysql","del_db",$dbn);
if (!ereg("^[0-9a-z]*$",$dbn)) {
$err->raise("mysql",2);
return false;
}
$dbname=$mem->user["login"].($dbn?"_":"").$dbn;
$dbname=addslashes($mem->user["login"].($dbn?"_":"").$dbn);
$db->query("SELECT login FROM db WHERE db='$dbname';");
if (!$db->num_rows()) {
$err->raise("mysql",4);