diff options
author | Georgi Kodinov <Georgi.Kodinov@Oracle.com> | 2011-05-04 14:29:23 +0300 |
---|---|---|
committer | Georgi Kodinov <Georgi.Kodinov@Oracle.com> | 2011-05-04 14:29:23 +0300 |
commit | e76cd16967242b18a08f2f2a9608c85a6d1699d2 (patch) | |
tree | f6203178a6b0af093ece4a5d76b06c6c00754ec4 /sql/sql_load.cc | |
parent | be9fba494c0949513eafcff7a0a2695d1fd60f98 (diff) | |
parent | 59d7516005af28dce97c3f4251e2d7da2e31d203 (diff) | |
download | mariadb-git-e76cd16967242b18a08f2f2a9608c85a6d1699d2.tar.gz |
Merged 5.0-security->5.1-security
Diffstat (limited to 'sql/sql_load.cc')
-rw-r--r-- | sql/sql_load.cc | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/sql/sql_load.cc b/sql/sql_load.cc index c227fe69b62..a3796f71ea7 100644 --- a/sql/sql_load.cc +++ b/sql/sql_load.cc @@ -348,21 +348,21 @@ int mysql_load(THD *thd,sql_exchange *ex,TABLE_LIST *table_list, #if !defined(__WIN__) && ! defined(__NETWARE__) MY_STAT stat_info; - if (!my_stat(name,&stat_info,MYF(MY_WME))) - DBUG_RETURN(TRUE); + if (!my_stat(name, &stat_info, MYF(MY_WME))) + DBUG_RETURN(TRUE); // if we are not in slave thread, the file must be: if (!thd->slave_thread && - !((stat_info.st_mode & S_IROTH) == S_IROTH && // readable by others - (stat_info.st_mode & S_IFLNK) != S_IFLNK && // and not a symlink - ((stat_info.st_mode & S_IFREG) == S_IFREG || - (stat_info.st_mode & S_IFIFO) == S_IFIFO))) + !((stat_info.st_mode & S_IROTH) == S_IROTH && // readable by others + (stat_info.st_mode & S_IFLNK) != S_IFLNK && // and not a symlink + ((stat_info.st_mode & S_IFREG) == S_IFREG || // and a regular file + (stat_info.st_mode & S_IFIFO) == S_IFIFO))) // or FIFO { - my_error(ER_TEXTFILE_NOT_READABLE, MYF(0), name); - DBUG_RETURN(TRUE); + my_error(ER_TEXTFILE_NOT_READABLE, MYF(0), name); + DBUG_RETURN(TRUE); } if ((stat_info.st_mode & S_IFIFO) == S_IFIFO) - is_fifo = 1; + is_fifo= 1; #endif if ((file=my_open(name,O_RDONLY,MYF(MY_WME))) < 0) |