Commit e6ff5f23 authored by unknown's avatar unknown

Windows-specific:

Fix for BUG#4375 "Windows specific directories are copied during
replication": in the Windows version of my_dir(), do not show hidden
or system files which Windows sometimes creates in the root directory
of drive (like RECYCLER and SYSTEM VOLUME INFORMATION directories) (so
this problem showed up only when the datadir was the root dir of a
drive).
This will make SHOW DATABASES display better, and will do no harm to
MySQL. For example, DROP DATABASE will not miss some files, as MySQL
creates no hidden or system files.


mysys/my_lib.c:
  In my_dir(), do not show hidden or system files
  which Windows sometimes creates.
parent 844c4973
...@@ -461,6 +461,15 @@ MY_DIR *my_dir(const char *path, myf MyFlags) ...@@ -461,6 +461,15 @@ MY_DIR *my_dir(const char *path, myf MyFlags)
else else
finfo.mystat= NULL; finfo.mystat= NULL;
/*
Do not show hidden or system files which Windows sometimes creates. We
would need to see how this can be achieved with a Borland compiler.
*/
#ifndef __BORLANDC__
if (attrib & (_A_HIDDEN | _A_SYSTEM))
continue;
#endif
if (push_dynamic(dir_entries_storage, (gptr)&finfo)) if (push_dynamic(dir_entries_storage, (gptr)&finfo))
goto error; goto error;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment