summaryrefslogtreecommitdiff
path: root/mysql-test/r/myisam_debug.result
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2017-05-12 14:27:49 +0200
committerSergei Golubchik <serg@mariadb.org>2017-05-15 22:23:10 +0200
commitf9264280d68dcbca2f9312c7d8620b2bcc9d0694 (patch)
tree4d68b8c47e162b862db88793d312bb93beab8e8b /mysql-test/r/myisam_debug.result
parent52aa200919b1fd9357c05bcdfc66a42e51f242b3 (diff)
downloadmariadb-git-f9264280d68dcbca2f9312c7d8620b2bcc9d0694.tar.gz
MDEV-12761 Error return from external_lock make the server crash
bunch of bugs when external_lock() fails on unlock: * mi_lock_database() used mi_mark_crashed() under share->intern_lock, but mi_mark_crashed() itself locks this mutex. * handler::close() required table to be unlocked, but failed external_lock didn't count as unlock * mysql_unlock_tables() ignored all unlock errors, but they still set the error status in stmt_da.
Diffstat (limited to 'mysql-test/r/myisam_debug.result')
-rw-r--r--mysql-test/r/myisam_debug.result12
1 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/r/myisam_debug.result b/mysql-test/r/myisam_debug.result
index 36a8fe6c724..77de991bafd 100644
--- a/mysql-test/r/myisam_debug.result
+++ b/mysql-test/r/myisam_debug.result
@@ -27,3 +27,15 @@ CHECK TABLE t1;
Table Op Msg_type Msg_text
test.t1 check status OK
DROP TABLE t1,t2;
+call mtr.add_suppression('Incorrect key file for table');
+create table t1 (a int, index(a));
+lock tables t1 write;
+insert t1 values (1),(2),(1);
+set @old_dbug=@@debug_dbug;
+set debug_dbug='+d,mi_lock_database_failure';
+unlock tables;
+Warnings:
+Error 126 Incorrect key file for table './test/t1.MYI'; try to repair it
+Error 1015 Can't lock file (errno: 22 "Invalid argument")
+set debug_dbug=@old_dbug;
+drop table t1;