Commit 2e8fa1c2 authored by Nirbhay Choubey's avatar Nirbhay Choubey

MDEV-12058: MariaDB Test Suite issue with test sys_vars.secure_file_priv.test

Try to remove bug50373.txt before using it in SELECT .. OUTFILE
(in case its a leftover from previous test runs).
parent 60c932a3
...@@ -21,6 +21,9 @@ SHOW VARIABLES LIKE 'secure_file_priv'; ...@@ -21,6 +21,9 @@ SHOW VARIABLES LIKE 'secure_file_priv';
--perl --perl
use File::Basename; use File::Basename;
my $protected_file= dirname($ENV{MYSQLTEST_VARDIR}).'/bug50373.txt'; my $protected_file= dirname($ENV{MYSQLTEST_VARDIR}).'/bug50373.txt';
# Ensure bug50373.txt does not exist (e.g. leftover from previous
# test runs).
unlink $protected_file;
open(FILE, ">", "$ENV{MYSQL_TMP_DIR}/bug50373.inc") or die; open(FILE, ">", "$ENV{MYSQL_TMP_DIR}/bug50373.inc") or die;
print FILE "SELECT * FROM t1 INTO OUTFILE '".$protected_file."';\n"; print FILE "SELECT * FROM t1 INTO OUTFILE '".$protected_file."';\n";
print FILE "DELETE FROM t1;\n"; print FILE "DELETE FROM t1;\n";
......
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