Bug#50373 --secure-file-priv=""
Correcting a patch misstake. The converted file path is placed in 'buff' not in opt_secure_file_priv. mysql-test/r/loaddata.result: * Updated test case; Since secure_file_priv now is normalized the previous values are changed. sql/mysqld.cc: * Fixed patch misstake
This commit is contained in:
parent
95da93d7ac
commit
3a626d1027
4
mysql-test/r/loaddata.result
Executable file → Normal file
4
mysql-test/r/loaddata.result
Executable file → Normal file
@ -204,10 +204,10 @@ a b c
|
|||||||
15 NULL Fifteen
|
15 NULL Fifteen
|
||||||
show variables like "secure_file_pri%";
|
show variables like "secure_file_pri%";
|
||||||
Variable_name Value
|
Variable_name Value
|
||||||
secure_file_priv MYSQLTEST_VARDIR/
|
secure_file_priv MYSQLTEST_VARDIR
|
||||||
select @@secure_file_priv;
|
select @@secure_file_priv;
|
||||||
@@secure_file_priv
|
@@secure_file_priv
|
||||||
MYSQLTEST_VARDIR/
|
MYSQLTEST_VARDIR
|
||||||
set @@secure_file_priv= 0;
|
set @@secure_file_priv= 0;
|
||||||
ERROR HY000: Variable 'secure_file_priv' is a read only variable
|
ERROR HY000: Variable 'secure_file_priv' is a read only variable
|
||||||
truncate table t1;
|
truncate table t1;
|
||||||
|
@ -8846,7 +8846,7 @@ static int fix_paths(void)
|
|||||||
convert_dirname(buff, opt_secure_file_priv, NullS);
|
convert_dirname(buff, opt_secure_file_priv, NullS);
|
||||||
char *secure_file_real_path= (char *)my_malloc(FN_REFLEN, MYF(MY_FAE));
|
char *secure_file_real_path= (char *)my_malloc(FN_REFLEN, MYF(MY_FAE));
|
||||||
if (secure_file_real_path == 0 ||
|
if (secure_file_real_path == 0 ||
|
||||||
my_realpath(secure_file_real_path, opt_secure_file_priv, 0))
|
my_realpath(secure_file_real_path, buff, 0))
|
||||||
{
|
{
|
||||||
sql_print_warning("Failed to normalize the argument for --secure-file-priv.");
|
sql_print_warning("Failed to normalize the argument for --secure-file-priv.");
|
||||||
return 1;
|
return 1;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user