summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <iggy/Administrator@amd64.>2006-11-20 15:18:57 -0500
committerunknown <iggy/Administrator@amd64.>2006-11-20 15:18:57 -0500
commita2beabfe1059d8c992dd69cebb886585ced2c445 (patch)
tree6998d894cc692028ff6e7029c0ffc3dde5e3f96c
parent2ff157dbeee9b175471f6f63084abe799de10562 (diff)
downloadmariadb-git-a2beabfe1059d8c992dd69cebb886585ced2c445.tar.gz
Bug#23983 ps.test fails to open shared library
- When a shared library argument is supplied, it's checked for an OS specific directory separator. The expected error is different depending on the separator used. Create OS specific versions of these tests. mysql-test/r/ps.result: Bug#23983 ps.test fails to open shared library - Moving to OS specific results. mysql-test/r/windows.result: Bug#23983 ps.test fails to open shared library - OS Specific result for shared library argument with path mysql-test/t/ps.test: Bug#23983 ps.test fails to open shared library - Moving to OS specific tests. mysql-test/t/windows.test: Bug#23983 ps.test fails to open shared library - OS Specific test for shared library argument with path mysql-test/r/ps_not_windows.result: Bug#23983 ps.test fails to open shared library - OS Specific result for shared library argument with path mysql-test/t/ps_not_windows.test: Bug#23983 ps.test fails to open shared library - OS Specific test for shared library argument with path
-rw-r--r--mysql-test/r/ps.result14
-rw-r--r--mysql-test/r/ps_not_windows.result14
-rw-r--r--mysql-test/r/windows.result14
-rw-r--r--mysql-test/t/ps.test14
-rw-r--r--mysql-test/t/ps_not_windows.test23
-rw-r--r--mysql-test/t/windows.test22
6 files changed, 73 insertions, 28 deletions
diff --git a/mysql-test/r/ps.result b/mysql-test/r/ps.result
index 617e289d30d..694a934f8b7 100644
--- a/mysql-test/r/ps.result
+++ b/mysql-test/r/ps.result
@@ -2090,14 +2090,6 @@ v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VI
deallocate prepare abc;
drop view v1;
drop table t1;
-create procedure proc_1() install plugin my_plug soname '/root/some_plugin.so';
-call proc_1();
-ERROR HY000: No paths allowed for shared library
-call proc_1();
-ERROR HY000: No paths allowed for shared library
-call proc_1();
-ERROR HY000: No paths allowed for shared library
-drop procedure proc_1;
create procedure proc_1() install plugin my_plug soname 'some_plugin.so';
call proc_1();
ERROR HY000: Can't open shared library
@@ -2112,12 +2104,6 @@ select func_1(), func_1(), func_1() from dual;
ERROR 42000: FUNCTION test.func_1 does not exist
drop function func_1;
ERROR 42000: FUNCTION test.func_1 does not exist
-prepare abc from "install plugin my_plug soname '/root/some_plugin.so'";
-execute abc;
-ERROR HY000: No paths allowed for shared library
-execute abc;
-ERROR HY000: No paths allowed for shared library
-deallocate prepare abc;
prepare abc from "install plugin my_plug soname 'some_plugin.so'";
deallocate prepare abc;
create procedure proc_1() uninstall plugin my_plug;
diff --git a/mysql-test/r/ps_not_windows.result b/mysql-test/r/ps_not_windows.result
new file mode 100644
index 00000000000..e58b6ec5cad
--- /dev/null
+++ b/mysql-test/r/ps_not_windows.result
@@ -0,0 +1,14 @@
+create procedure proc_1() install plugin my_plug soname '/root/some_plugin.so';
+call proc_1();
+ERROR HY000: No paths allowed for shared library
+call proc_1();
+ERROR HY000: No paths allowed for shared library
+call proc_1();
+ERROR HY000: No paths allowed for shared library
+drop procedure proc_1;
+prepare abc from "install plugin my_plug soname '/root/some_plugin.so'";
+execute abc;
+ERROR HY000: No paths allowed for shared library
+execute abc;
+ERROR HY000: No paths allowed for shared library
+deallocate prepare abc;
diff --git a/mysql-test/r/windows.result b/mysql-test/r/windows.result
index 039c5b1476e..e8c3c81a44e 100644
--- a/mysql-test/r/windows.result
+++ b/mysql-test/r/windows.result
@@ -6,3 +6,17 @@ use prn;
ERROR 42000: Unknown database 'prn'
create table nu (a int);
drop table nu;
+create procedure proc_1() install plugin my_plug soname '\\root\\some_plugin.dll';
+call proc_1();
+ERROR HY000: No paths allowed for shared library
+call proc_1();
+ERROR HY000: No paths allowed for shared library
+call proc_1();
+ERROR HY000: No paths allowed for shared library
+drop procedure proc_1;
+prepare abc from "install plugin my_plug soname '\\\\root\\\\some_plugin.dll'";
+execute abc;
+ERROR HY000: No paths allowed for shared library
+execute abc;
+ERROR HY000: No paths allowed for shared library
+deallocate prepare abc;
diff --git a/mysql-test/t/ps.test b/mysql-test/t/ps.test
index 1a19355406a..827f46664bf 100644
--- a/mysql-test/t/ps.test
+++ b/mysql-test/t/ps.test
@@ -2092,14 +2092,6 @@ drop view v1;
drop table t1;
-create procedure proc_1() install plugin my_plug soname '/root/some_plugin.so';
---error ER_UDF_NO_PATHS
-call proc_1();
---error ER_UDF_NO_PATHS
-call proc_1();
---error ER_UDF_NO_PATHS
-call proc_1();
-drop procedure proc_1;
create procedure proc_1() install plugin my_plug soname 'some_plugin.so';
--replace_regex /(Can\'t open shared library).*$/\1/
--error ER_CANT_OPEN_LIBRARY
@@ -2119,12 +2111,6 @@ delimiter ;|
select func_1(), func_1(), func_1() from dual;
--error ER_SP_DOES_NOT_EXIST
drop function func_1;
-prepare abc from "install plugin my_plug soname '/root/some_plugin.so'";
---error ER_UDF_NO_PATHS
-execute abc;
---error ER_UDF_NO_PATHS
-execute abc;
-deallocate prepare abc;
prepare abc from "install plugin my_plug soname 'some_plugin.so'";
deallocate prepare abc;
diff --git a/mysql-test/t/ps_not_windows.test b/mysql-test/t/ps_not_windows.test
new file mode 100644
index 00000000000..0d97df96285
--- /dev/null
+++ b/mysql-test/t/ps_not_windows.test
@@ -0,0 +1,23 @@
+# Non-windows specific ps tests.
+--source include/not_windows.inc
+
+#
+# Bug #20665: All commands supported in Stored Procedures should work in
+# Prepared Statements
+#
+
+create procedure proc_1() install plugin my_plug soname '/root/some_plugin.so';
+--error ER_UDF_NO_PATHS
+call proc_1();
+--error ER_UDF_NO_PATHS
+call proc_1();
+--error ER_UDF_NO_PATHS
+call proc_1();
+drop procedure proc_1;
+
+prepare abc from "install plugin my_plug soname '/root/some_plugin.so'";
+--error ER_UDF_NO_PATHS
+execute abc;
+--error ER_UDF_NO_PATHS
+execute abc;
+deallocate prepare abc;
diff --git a/mysql-test/t/windows.test b/mysql-test/t/windows.test
index d6bcfeb8cb3..4dab646df2c 100644
--- a/mysql-test/t/windows.test
+++ b/mysql-test/t/windows.test
@@ -18,3 +18,25 @@ create table nu (a int);
drop table nu;
# End of 4.1 tests
+
+#
+# Bug #20665: All commands supported in Stored Procedures should work in
+# Prepared Statements
+#
+
+create procedure proc_1() install plugin my_plug soname '\\root\\some_plugin.dll';
+--error ER_UDF_NO_PATHS
+call proc_1();
+--error ER_UDF_NO_PATHS
+call proc_1();
+--error ER_UDF_NO_PATHS
+call proc_1();
+drop procedure proc_1;
+
+prepare abc from "install plugin my_plug soname '\\\\root\\\\some_plugin.dll'";
+--error ER_UDF_NO_PATHS
+execute abc;
+--error ER_UDF_NO_PATHS
+execute abc;
+deallocate prepare abc;
+