1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

fix for bug #12591 (SHOW TABLES FROM dbname produces wrong error message)

This commit is contained in:
andrey@lmy004.
2005-08-17 17:51:10 +02:00
parent f97d993120
commit 4ff51a5743
3 changed files with 14 additions and 1 deletions

View File

@@ -264,8 +264,14 @@ mysql_find_files(THD *thd,List<char> *files, const char *db,const char *path,
bzero((char*) &table_list,sizeof(table_list));
if (!(dirp = my_dir(path,MYF(MY_WME | (dir ? MY_WANT_STAT : 0)))))
if (!(dirp = my_dir(path,MYF(dir ? MY_WANT_STAT : 0))))
{
if (my_errno == ENOENT)
my_error(ER_BAD_DB_ERROR, MYF(ME_BELL+ME_WAITTANG), db);
else
my_error(ER_CANT_READ_DIR, MYF(ME_BELL+ME_WAITTANG), path, my_errno);
DBUG_RETURN(-1);
}
for (i=0 ; i < (uint) dirp->number_off_files ; i++)
{