mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-33783 CREATE SERVER segfaults on wrong mysql.servers
Do basic checking of mysql.servers compatibility.
This commit is contained in:
@@ -22,3 +22,18 @@ DROP SERVER s1;
|
||||
CREATE SERVER s1 FOREIGN DATA WRAPPER mysql OPTIONS(SOCKET 'bar');
|
||||
SELECT * FROM mysql.servers;
|
||||
DROP SERVER s1;
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-33783 CREATE SERVER segfaults on wrong mysql.servers
|
||||
--echo #
|
||||
create server s1 foreign data wrapper foo options(user 'a');
|
||||
alter server s1 options(host 'server.example.org');
|
||||
rename table mysql.servers to mysql.servers_save;
|
||||
create table mysql.servers (x int);
|
||||
--error ER_FOREIGN_SERVER_DOESNT_EXIST
|
||||
alter server s1 options(host 'server.example.org');
|
||||
--error ER_CANT_FIND_SYSTEM_REC
|
||||
create server s2 foreign data wrapper foo options(user 'a');
|
||||
drop table mysql.servers;
|
||||
rename table mysql.servers_save to mysql.servers;
|
||||
drop server s1;
|
||||
|
Reference in New Issue
Block a user