diff options
author | kroki/tomash@moonlight.intranet <> | 2006-11-21 17:23:54 +0300 |
---|---|---|
committer | kroki/tomash@moonlight.intranet <> | 2006-11-21 17:23:54 +0300 |
commit | f6235bc58caaab9fb76bfd82b5fe9f1f0a1b2606 (patch) | |
tree | c3337bea76df7e741e64f0a208accf9881ec5992 /mysql-test/t/ps.test | |
parent | 5ba9ab49b76bdb1b291c50a2e4284a22107cc9a9 (diff) | |
download | mariadb-git-f6235bc58caaab9fb76bfd82b5fe9f1f0a1b2606.tar.gz |
Update after merge.
Use mutex when reading prepared_stmt_count global status variable.
Update test case for bug 16365 and bug 23159: add test for
prepared_stmt_count being decreased when some connection that had
prepared statements is closed.
Diffstat (limited to 'mysql-test/t/ps.test')
-rw-r--r-- | mysql-test/t/ps.test | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/mysql-test/t/ps.test b/mysql-test/t/ps.test index 0a739c05eda..a64764f623f 100644 --- a/mysql-test/t/ps.test +++ b/mysql-test/t/ps.test @@ -950,7 +950,18 @@ select @@max_prepared_stmt_count; show status like 'prepared_stmt_count'; disconnect con1; connection default; +# Wait for the connection to die: deal with a possible race deallocate prepare stmt; +let $query= select variable_value from information_schema.global_status + where variable_name = 'prepared_stmt_count'; +let $count= `$query`; +if ($count) +{ +--sleep 1 + let $count= `$query`; +} +select @@max_prepared_stmt_count; +show status like 'prepared_stmt_count'; # # Restore the old value. # |