mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 19:37:16 +02:00
Merge zippy.cornsilk.net:/home/cmiller/work/mysql/bug#33464/my51-bug#33464
into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-5.1-build mysql-test/r/grant.result: Auto merged mysql-test/t/grant.test: Auto merged
This commit is contained in:
commit
f6d51ae79f
4 changed files with 101 additions and 101 deletions
|
|
@ -1400,4 +1400,66 @@ DROP USER mysqltest_1@localhost;
|
|||
FLUSH PRIVILEGES;
|
||||
|
||||
|
||||
#
|
||||
# Bug#33464: DROP FUNCTION caused a crash.
|
||||
#
|
||||
CREATE DATABASE dbbug33464;
|
||||
CREATE USER 'userbug33464'@'localhost';
|
||||
|
||||
GRANT CREATE ROUTINE ON dbbug33464.* TO 'userbug33464'@'localhost';
|
||||
|
||||
--replace_result $MASTER_MYPORT MYSQL_PORT $MASTER_MYSOCK MYSQL_SOCK
|
||||
connect (connbug33464, localhost, userbug33464, , dbbug33464);
|
||||
--source suite/funcs_1/include/show_connection.inc
|
||||
|
||||
--disable_warnings
|
||||
DROP PROCEDURE IF EXISTS sp3;
|
||||
DROP FUNCTION IF EXISTS fn1;
|
||||
--enable_warnings
|
||||
|
||||
delimiter //;
|
||||
CREATE PROCEDURE sp3(v1 char(20))
|
||||
BEGIN
|
||||
SELECT * from dbbug33464.t6 where t6.f2= 'xyz';
|
||||
END//
|
||||
delimiter ;//
|
||||
|
||||
delimiter //;
|
||||
CREATE FUNCTION fn1() returns char(50) SQL SECURITY INVOKER
|
||||
BEGIN
|
||||
return 1;
|
||||
END//
|
||||
delimiter ;//
|
||||
|
||||
delimiter //;
|
||||
CREATE FUNCTION fn2() returns char(50) SQL SECURITY DEFINER
|
||||
BEGIN
|
||||
return 2;
|
||||
END//
|
||||
delimiter ;//
|
||||
|
||||
disconnect connbug33464;
|
||||
|
||||
# cleanup
|
||||
connection default;
|
||||
USE dbbug33464;
|
||||
--source suite/funcs_1/include/show_connection.inc
|
||||
|
||||
SELECT fn1();
|
||||
SELECT fn2();
|
||||
|
||||
--error 0, ER_CANNOT_USER
|
||||
DROP USER 'userbug33464'@'localhost';
|
||||
|
||||
DROP FUNCTION fn1;
|
||||
DROP FUNCTION fn2;
|
||||
DROP PROCEDURE sp3;
|
||||
|
||||
--error 0, ER_CANNOT_USER
|
||||
DROP USER 'userbug33464'@'localhost';
|
||||
|
||||
use test;
|
||||
DROP DATABASE dbbug33464;
|
||||
|
||||
|
||||
--echo End of 5.1 tests
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue