2969 Bjorn Munch 2010-09-20 [merge]
upmerge 56753,56787
modified:
client/mysqltest.cc
mysql-test/lib/mtr_report.pm
mysql-test/r/mysqltest.result
mysql-test/suite/rpl/t/rpl_row_tbl_metadata.test
mysql-test/suite/sys_vars/t/div_precision_increment_func.test
mysql-test/t/mysqltest.test
2968 Bjorn Munch 2010-09-20 [merge]
merge from trunk
modified:
client/CMakeLists.txt
include/CMakeLists.txt
include/Makefile.am
mysql-test/r/sp-destruct.result
mysql-test/t/sp-destruct.test
scripts/CMakeLists.txt
scripts/make_win_bin_dist
sql/CMakeLists.txt
sql/mdl.cc
sql/mdl.h
sql/sp.cc
sql/sql_base.cc
sql/sql_base.h
sql/table.cc
2967 Bjorn Munch 2010-09-14 [merge]
upmerge 55426(55546), 56647
modified:
client/mysqltest.cc
=== modified file 'client/CMakeLists.txt'
--- a/client/CMakeLists.txt 2010-08-12 15:19:57 +0000
+++ b/client/CMakeLists.txt 2010-09-06 11:26:23 +0000
@@ -64,7 +64,10 @@ MYSQL_ADD_EXECUTABLE(mysqlslap mysqlslap
SET_SOURCE_FILES_PROPERTIES(mysqlslap.c PROPERTIES COMPILE_FLAGS "-DTHREADS")
TARGET_LINK_LIBRARIES(mysqlslap mysqlclient)
-ADD_EXECUTABLE(echo echo.c)
+# "WIN32" also covers 64 bit. "echo" is used in some files below "mysql-test/".
+IF(WIN32)
+ MYSQL_ADD_EXECUTABLE(echo echo.c)
+ENDIF(WIN32)
SET_TARGET_PROPERTIES (mysqlcheck mysqldump mysqlimport mysql_upgrade mysqlshow mysqlslap
PROPERTIES HAS_CXX TRUE)
=== modified file 'client/mysqltest.cc'
--- a/client/mysqltest.cc 2010-09-14 12:23:53 +0000
+++ b/client/mysqltest.cc 2010-09-20 08:24:39 +0000
@@ -2185,8 +2185,14 @@ void var_query_set(VAR *var, const char
DBUG_ENTER("var_query_set");
LINT_INIT(res);
+ /* Only white space or ) allowed past ending ` */
while (end > query && *end != '`')
+ {
+ if (*end && (*end != ' ' && *end != '\t' && *end != '\n' && *end != ')'))
+ die("Spurious text after `query` expression");
--end;
+ }
+
if (query == end)
die("Syntax error in query, missing '`'");
++query;
=== modified file 'include/CMakeLists.txt'
--- a/include/CMakeLists.txt 2010-08-12 15:27:53 +0000
+++ b/include/CMakeLists.txt 2010-09-13 10:26:57 +0000
@@ -54,6 +54,7 @@ SET(HEADERS
keycache.h
m_ctype.h
my_attribute.h
+ my_compiler.h
${HEADERS_GEN_CONFIGURE}
)
=== modified file 'include/Makefile.am'
--- a/include/Makefile.am 2010-09-01 13:05:01 +0000
+++ b/include/Makefile.am 2010-09-13 10:36:27 +0000
@@ -32,8 +32,9 @@ pkginclude_HEADERS = $(HEADERS_ABI) my_d
decimal.h errmsg.h my_global.h my_net.h \
my_getopt.h sslopt-longopts.h my_dir.h \
sslopt-vars.h sslopt-case.h sql_common.h keycache.h \
- m_ctype.h my_attribute.h $(HEADERS_GEN_CONFIGURE) \
- $(HEADERS_GEN_MAKE) probes_mysql.h probes_mysql_nodtrace.h
+ m_ctype.h my_attribute.h my_compiler.h \
+ $(HEADERS_GEN_CONFIGURE) $(HEADERS_GEN_MAKE) \
+ probes_mysql.h probes_mysql_nodtrace.h
noinst_HEADERS = lf.h my_bit.h \
heap.h my_bitmap.h my_uctype.h password.h \
@@ -47,7 +48,7 @@ noinst_HEADERS = lf.h my_bit.h \
my_user.h my_atomic.h atomic/nolock.h \
atomic/rwlock.h atomic/x86-gcc.h atomic/generic-msvc.h \
atomic/gcc_builtins.h my_libwrap.h my_stacktrace.h \
- atomic/solaris.h mysql/innodb_priv.h my_compiler.h
+ atomic/solaris.h mysql/innodb_priv.h
pkgpsiinclude_HEADERS = mysql/psi/psi.h mysql/psi/mysql_thread.h \
mysql/psi/mysql_file.h \
=== modified file 'mysql-test/lib/mtr_report.pm'
--- a/mysql-test/lib/mtr_report.pm 2010-06-10 08:34:16 +0000
+++ b/mysql-test/lib/mtr_report.pm 2010-09-20 08:12:39 +0000
@@ -229,7 +229,8 @@ sub mtr_report_stats ($$;$) {
# Find out how we where doing
# ----------------------------------------------------------------------
- my $tot_skiped= 0;
+ my $tot_skipped= 0;
+ my $tot_skipdetect= 0;
my $tot_passed= 0;
my $tot_failed= 0;
my $tot_tests= 0;
@@ -246,8 +247,9 @@ sub mtr_report_stats ($$;$) {
}
elsif ( $tinfo->{'result'} eq 'MTR_RES_SKIPPED' )
{
- # Test was skipped
- $tot_skiped++;
+ # Test was skipped (disabled not counted)
+ $tot_skipped++ unless $tinfo->{'disable'};
+ $tot_skipdetect++ if $tinfo->{'skip_detected_by_test'};
}
elsif ( $tinfo->{'result'} eq 'MTR_RES_PASSED' )
{
@@ -376,6 +378,9 @@ sub mtr_report_stats ($$;$) {
print "All $tot_tests tests were successful.\n\n";
}
+ print "$tot_skipped tests were skipped, ".
+ "$tot_skipdetect by the test itself.\n\n" if $tot_skipped;
+
if ( $tot_failed != 0 || $found_problems)
{
mtr_error("there were failing test cases") unless $dont_error;
=== modified file 'mysql-test/r/mysqltest.result'
--- a/mysql-test/r/mysqltest.result 2010-09-01 14:02:56 +0000
+++ b/mysql-test/r/mysqltest.result 2010-09-20 08:24:39 +0000
@@ -177,6 +177,9 @@ mysqltest: At line 1: End of line junk d
"
mysqltest: At line 1: Extra delimiter ";" found
mysqltest: At line 1: Extra delimiter ";" found
+mysqltest: At line 1: Spurious text after `query` expression
+mysqltest: At line 1: Spurious text after `query` expression
+mysqltest: At line 2: Spurious text after `query` expression
mysqltest: At line 1: Missing argument(s) to 'error'
mysqltest: At line 1: Missing argument(s) to 'error'
mysqltest: At line 1: The sqlstate definition must start with an uppercase S
=== modified file 'mysql-test/r/sp-destruct.result'
--- a/mysql-test/r/sp-destruct.result 2010-03-03 09:24:53 +0000
+++ b/mysql-test/r/sp-destruct.result 2010-09-13 09:58:11 +0000
@@ -134,3 +134,19 @@ Warning 1405 Failed to revoke all privil
# Restore the procs_priv table
RENAME TABLE procs_priv_backup TO mysql.procs_priv;
FLUSH TABLE mysql.procs_priv;
+#
+# Bug #56137 "Assertion `thd->lock == 0' failed on upgrading from
+# 5.1.50 to 5.5.6".
+#
+drop database if exists mysqltest;
+# Backup mysql.proc.
+flush table mysql.proc;
+create database mysqltest;
+# Corrupt mysql.proc to make it unusable by current version of server.
+alter table mysql.proc drop column type;
+# The below statement should not cause assertion failure.
+drop database mysqltest;
+Warnings:
+Error 1695 Column count of mysql.proc is wrong. Expected 20, found 19. The table is probably corrupted
+# Restore mysql.proc.
+drop table mysql.proc;
=== modified file 'mysql-test/suite/rpl/t/rpl_row_tbl_metadata.test'
--- a/mysql-test/suite/rpl/t/rpl_row_tbl_metadata.test 2010-01-14 10:49:40 +0000
+++ b/mysql-test/suite/rpl/t/rpl_row_tbl_metadata.test 2010-09-15 12:56:22 +0000
@@ -205,7 +205,7 @@ DROP TABLE `t1`;
-- echo === Using mysqlbinlog to detect failure. Before the patch mysqlbinlog would find a corrupted event, thence would fail.
--- let $MYSQLD_DATADIR= `SELECT @@datadir`;
+-- let $MYSQLD_DATADIR= `SELECT @@datadir`
-- exec $MYSQL_BINLOG $MYSQLD_DATADIR/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mysqlbinlog_bug42749.binlog
-- remove_file $MYSQLTEST_VARDIR/tmp/mysqlbinlog_bug42749.binlog
@@ -330,7 +330,7 @@ while($ntables)
-- echo ### assertion: check that binlog is not corrupt. Using mysqlbinlog to
-- echo ### detect failure. Before the patch mysqlbinlog would find
-- echo ### a corrupted event, thence would fail.
--- let $MYSQLD_DATADIR= `SELECT @@datadir`;
+-- let $MYSQLD_DATADIR= `SELECT @@datadir`
-- exec $MYSQL_BINLOG -v --hex $MYSQLD_DATADIR/master-bin.000001 > $MYSQLTEST_VARDIR/tmp/mysqlbinlog_bug50018.binlog
## clean up
=== modified file 'mysql-test/suite/sys_vars/t/div_precision_increment_func.test'
--- a/mysql-test/suite/sys_vars/t/div_precision_increment_func.test 2009-12-22 09:35:56 +0000
+++ b/mysql-test/suite/sys_vars/t/div_precision_increment_func.test 2010-09-20 08:21:55 +0000
@@ -19,7 +19,7 @@
# #
################################################################################
-let $save_div_precision_increment = `SELECT @@global.div_precision_increment`
+let $save_div_precision_increment = `SELECT @@global.div_precision_increment`;
#SET @save_div_precision_increment = @@global.div_precision_increment;
=== modified file 'mysql-test/t/mysqltest.test'
--- a/mysql-test/t/mysqltest.test 2010-09-01 14:02:56 +0000
+++ b/mysql-test/t/mysqltest.test 2010-09-20 08:24:39 +0000
@@ -494,6 +494,23 @@ remove_file $MYSQLTEST_VARDIR/tmp/mysqlt
--error 1
--exec echo "--disable_query_log;" | $MYSQL_TEST 2>&1
+#
+# Extra text after ``
+#
+--error 1
+-- exec echo "let \$x= \`select 1\` BOO ;" | $MYSQL_TEST 2>&1
+--error 1
+-- exec echo "--let \$x= \`select 1\`;" | $MYSQL_TEST 2>&1
+--write_file $MYSQLTEST_VARDIR/tmp/mysqltest.sql
+# Missing ; in next line should be detected and cause failure
+let $x= `select 1`
+let $x= 2;
+echo $x;
+EOF
+--error 1
+--exec $MYSQL_TEST < $MYSQLTEST_VARDIR/tmp/mysqltest.sql 2>&1
+remove_file $MYSQLTEST_VARDIR/tmp/mysqltest.sql;
+
# Allow trailing # comment
--sleep 1 # Wait for insert delayed to be executed.
=== modified file 'mysql-test/t/sp-destruct.test'
--- a/mysql-test/t/sp-destruct.test 2010-04-16 14:24:06 +0000
+++ b/mysql-test/t/sp-destruct.test 2010-09-13 09:58:11 +0000
@@ -222,3 +222,33 @@ SHOW WARNINGS;
--echo # Restore the procs_priv table
RENAME TABLE procs_priv_backup TO mysql.procs_priv;
FLUSH TABLE mysql.procs_priv;
+
+
+--echo #
+--echo # Bug #56137 "Assertion `thd->lock == 0' failed on upgrading from
+--echo # 5.1.50 to 5.5.6".
+--echo #
+--disable_warnings
+drop database if exists mysqltest;
+--enable_warnings
+--echo # Backup mysql.proc.
+flush table mysql.proc;
+let $MYSQLD_DATADIR= `select @@datadir`;
+--copy_file $MYSQLD_DATADIR/mysql/proc.frm $MYSQLTEST_VARDIR/tmp/proc.frm
+--copy_file $MYSQLD_DATADIR/mysql/proc.MYD $MYSQLTEST_VARDIR/tmp/proc.MYD
+--copy_file $MYSQLD_DATADIR/mysql/proc.MYI $MYSQLTEST_VARDIR/tmp/proc.MYI
+
+create database mysqltest;
+--echo # Corrupt mysql.proc to make it unusable by current version of server.
+alter table mysql.proc drop column type;
+--echo # The below statement should not cause assertion failure.
+drop database mysqltest;
+
+--echo # Restore mysql.proc.
+drop table mysql.proc;
+--copy_file $MYSQLTEST_VARDIR/tmp/proc.frm $MYSQLD_DATADIR/mysql/proc.frm
+--copy_file $MYSQLTEST_VARDIR/tmp/proc.MYD $MYSQLD_DATADIR/mysql/proc.MYD
+--copy_file $MYSQLTEST_VARDIR/tmp/proc.MYI $MYSQLD_DATADIR/mysql/proc.MYI
+--remove_file $MYSQLTEST_VARDIR/tmp/proc.frm
+--remove_file $MYSQLTEST_VARDIR/tmp/proc.MYD
+--remove_file $MYSQLTEST_VARDIR/tmp/proc.MYI
=== modified file 'scripts/CMakeLists.txt'
--- a/scripts/CMakeLists.txt 2010-08-23 17:01:12 +0000
+++ b/scripts/CMakeLists.txt 2010-09-13 10:26:57 +0000
@@ -139,6 +139,7 @@ ELSE()
ENDIF()
SET(HOSTNAME "hostname")
+SET(MYSQLD_USER "mysql")
# Required for mysqlbug until autotools are deprecated, once done remove these
# and expand default cmake variables
=== modified file 'scripts/make_win_bin_dist'
--- a/scripts/make_win_bin_dist 2010-07-23 20:14:04 +0000
+++ b/scripts/make_win_bin_dist 2010-08-31 14:33:19 +0000
@@ -260,6 +260,7 @@ cp include/mysql.h \
include/keycache.h \
include/m_ctype.h \
include/my_attribute.h \
+ include/my_compiler.h \
include/mysqld_error.h \
include/sql_state.h \
include/mysqld_ername.h \
=== modified file 'sql/CMakeLists.txt'
--- a/sql/CMakeLists.txt 2010-08-20 08:48:59 +0000
+++ b/sql/CMakeLists.txt 2010-09-13 09:58:11 +0000
@@ -289,8 +289,7 @@ IF(WIN32 AND MYSQLD_EXECUTABLE)
COMMAND ${CMAKE_COMMAND}
${CONFIG_PARAM} -P ${CMAKE_CURRENT_BINARY_DIR}/create_initial_db.cmake
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/data
- COMMAND ${CMAKE_COMMAND} -E touch initdb.dep
- WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
+ COMMAND ${CMAKE_COMMAND} -E touch ${CMAKE_CURRENT_BINARY_DIR}/initdb.dep
DEPENDS mysqld
)
ADD_CUSTOM_TARGET(initial_database
=== modified file 'sql/mdl.cc'
--- a/sql/mdl.cc 2010-08-20 08:48:59 +0000
+++ b/sql/mdl.cc 2010-09-13 10:26:57 +0000
@@ -124,7 +124,6 @@ public:
Deadlock_detection_visitor(MDL_context *start_node_arg)
: m_start_node(start_node_arg),
m_victim(NULL),
- m_current_search_depth(0),
m_found_deadlock(FALSE)
{}
virtual bool enter_node(MDL_context *node);
@@ -133,6 +132,8 @@ public:
virtual bool inspect_edge(MDL_context *dest);
MDL_context *get_victim() const { return m_victim; }
+
+ void abort_traversal(MDL_context *node);
private:
/**
Change the deadlock victim to a new one if it has lower deadlock
@@ -147,13 +148,6 @@ private:
MDL_context *m_start_node;
/** If a deadlock is found, the context that identifies the victim. */
MDL_context *m_victim;
- /** Set to the 0 at start. Increased whenever
- we descend into another MDL context (aka traverse to the next
- wait-for graph node). When MAX_SEARCH_DEPTH is reached, we
- assume that a deadlock is found, even if we have not found a
- loop.
- */
- uint m_current_search_depth;
/** TRUE if we found a deadlock. */
bool m_found_deadlock;
/**
@@ -187,7 +181,7 @@ private:
bool Deadlock_detection_visitor::enter_node(MDL_context *node)
{
- m_found_deadlock= ++m_current_search_depth >= MAX_SEARCH_DEPTH;
+ m_found_deadlock= m_current_search_depth >= MAX_SEARCH_DEPTH;
if (m_found_deadlock)
{
DBUG_ASSERT(! m_victim);
@@ -207,7 +201,6 @@ bool Deadlock_detection_visitor::enter_n
void Deadlock_detection_visitor::leave_node(MDL_context *node)
{
- --m_current_search_depth;
if (m_found_deadlock)
opt_change_victim_to(node);
}
@@ -252,6 +245,21 @@ Deadlock_detection_visitor::opt_change_v
/**
+ Abort traversal of a wait-for graph and report a deadlock.
+
+ @param node Node which we were about to visit when abort
+ was initiated.
+*/
+
+void Deadlock_detection_visitor::abort_traversal(MDL_context *node)
+{
+ DBUG_ASSERT(! m_victim);
+ m_found_deadlock= TRUE;
+ opt_change_victim_to(node);
+}
+
+
+/**
Get a bit corresponding to enum_mdl_type value in a granted/waiting bitmaps
and compatibility matrices.
*/
@@ -2056,8 +2064,13 @@ bool MDL_lock::visit_subgraph(MDL_ticket
are visiting it but this is OK: in the worst case we might do some
extra work and one more context might be chosen as a victim.
*/
+ ++gvisitor->m_current_search_depth;
+
if (gvisitor->enter_node(src_ctx))
+ {
+ --gvisitor->m_current_search_depth;
goto end;
+ }
/*
We do a breadth-first search first -- that is, inspect all
@@ -2114,6 +2127,7 @@ bool MDL_lock::visit_subgraph(MDL_ticket
end_leave_node:
gvisitor->leave_node(src_ctx);
+ --gvisitor->m_current_search_depth;
end:
mysql_prlock_unlock(&m_rwlock);
=== modified file 'sql/mdl.h'
--- a/sql/mdl.h 2010-08-20 08:48:59 +0000
+++ b/sql/mdl.h 2010-09-13 10:26:57 +0000
@@ -385,7 +385,10 @@ public:
virtual bool inspect_edge(MDL_context *dest) = 0;
virtual ~MDL_wait_for_graph_visitor();
- MDL_wait_for_graph_visitor() :m_lock_open_count(0) {}
+ MDL_wait_for_graph_visitor() :m_lock_open_count(0),
+ m_current_search_depth(0)
+ { }
+ virtual void abort_traversal(MDL_context *node) = 0;
public:
/**
XXX, hack: During deadlock search, we may need to
@@ -396,6 +399,17 @@ public:
LOCK_open since it has significant performance impacts.
*/
uint m_lock_open_count;
+ /**
+ Set to the 0 at start. Increased whenever
+ we descend into another MDL context (aka traverse to the next
+ wait-for graph node). When MAX_SEARCH_DEPTH is reached, we
+ assume that a deadlock is found, even if we have not found a
+ loop.
+
+ XXX: This member belongs to this class only temporarily until
+ bug #56405 is fixed.
+ */
+ uint m_current_search_depth;
};
/**
=== modified file 'sql/sp.cc'
--- a/sql/sp.cc 2010-07-29 13:37:49 +0000
+++ b/sql/sp.cc 2010-09-13 09:58:11 +0000
@@ -440,6 +440,7 @@ static TABLE *open_proc_table_for_update
{
TABLE_LIST table_list;
TABLE *table;
+ MDL_ticket *mdl_savepoint= thd->mdl_context.mdl_savepoint();
DBUG_ENTER("open_proc_table_for_update");
table_list.init_one_table("mysql", 5, "proc", 4, "proc", TL_WRITE);
@@ -450,6 +451,9 @@ static TABLE *open_proc_table_for_update
if (!proc_table_intact.check(table, &proc_table_def))
DBUG_RETURN(table);
+ close_thread_tables(thd);
+ thd->mdl_context.rollback_to_savepoint(mdl_savepoint);
+
DBUG_RETURN(NULL);
}
=== modified file 'sql/sql_base.cc'
--- a/sql/sql_base.cc 2010-08-20 08:48:59 +0000
+++ b/sql/sql_base.cc 2010-09-13 10:26:57 +0000
@@ -100,6 +100,8 @@ bool No_such_table_error_handler::safely
TABLE_SHAREs, refresh_version and the table id counter.
*/
mysql_mutex_t LOCK_open;
+mysql_mutex_t LOCK_dd_owns_lock_open;
+uint dd_owns_lock_open= 0;
#ifdef HAVE_PSI_INTERFACE
static PSI_mutex_key key_LOCK_open;
@@ -298,6 +300,7 @@ bool table_def_init(void)
init_tdc_psi_keys();
#endif
mysql_mutex_init(key_LOCK_open, &LOCK_open, MY_MUTEX_INIT_FAST);
+ mysql_mutex_init(NULL, &LOCK_dd_owns_lock_open, MY_MUTEX_INIT_FAST);
oldest_unused_share= &end_of_unused_share;
end_of_unused_share.prev= &oldest_unused_share;
@@ -341,6 +344,7 @@ void table_def_free(void)
table_def_inited= 0;
/* Free table definitions. */
my_hash_free(&table_def_cache);
+ mysql_mutex_destroy(&LOCK_dd_owns_lock_open);
mysql_mutex_destroy(&LOCK_open);
}
DBUG_VOID_RETURN;
=== modified file 'sql/sql_base.h'
--- a/sql/sql_base.h 2010-08-20 08:48:59 +0000
+++ b/sql/sql_base.h 2010-09-13 10:26:57 +0000
@@ -71,6 +71,8 @@ enum enum_tdc_remove_table_type {TDC_RT_
bool check_dup(const char *db, const char *name, TABLE_LIST *tables);
extern mysql_mutex_t LOCK_open;
+extern mysql_mutex_t LOCK_dd_owns_lock_open;
+extern uint dd_owns_lock_open;
bool table_cache_init(void);
void table_cache_free(void);
bool table_def_init(void);
=== modified file 'sql/table.cc'
--- a/sql/table.cc 2010-08-26 15:17:35 +0000
+++ b/sql/table.cc 2010-09-13 10:26:57 +0000
@@ -3092,7 +3092,30 @@ bool TABLE_SHARE::visit_subgraph(Wait_fo
holding a write-lock on MDL_lock::m_rwlock.
*/
if (gvisitor->m_lock_open_count++ == 0)
+ {
+ /*
+ To circumvent bug #56405 "Deadlock in the MDL deadlock detector"
+ we don't try to lock LOCK_open mutex if some thread doing
+ deadlock detection already owns it and current search depth is
+ greater than 0. Instead we report a deadlock.
+
+ TODO/FIXME: The proper fix for this bug is to use rwlocks for
+ protection of table shares/instead of LOCK_open.
+ Unfortunately it requires more effort/has significant
+ performance effect.
+ */
+ mysql_mutex_lock(&LOCK_dd_owns_lock_open);
+ if (gvisitor->m_current_search_depth > 0 && dd_owns_lock_open > 0)
+ {
+ mysql_mutex_unlock(&LOCK_dd_owns_lock_open);
+ --gvisitor->m_lock_open_count;
+ gvisitor->abort_traversal(src_ctx);
+ return TRUE;
+ }
+ ++dd_owns_lock_open;
+ mysql_mutex_unlock(&LOCK_dd_owns_lock_open);
mysql_mutex_lock(&LOCK_open);
+ }
I_P_List_iterator <TABLE, TABLE_share> tables_it(used_tables);
@@ -3107,8 +3130,12 @@ bool TABLE_SHARE::visit_subgraph(Wait_fo
goto end;
}
+ ++gvisitor->m_current_search_depth;
if (gvisitor->enter_node(src_ctx))
+ {
+ --gvisitor->m_current_search_depth;
goto end;
+ }
while ((table= tables_it++))
{
@@ -3131,10 +3158,16 @@ bool TABLE_SHARE::visit_subgraph(Wait_fo
end_leave_node:
gvisitor->leave_node(src_ctx);
+ --gvisitor->m_current_search_depth;
end:
if (gvisitor->m_lock_open_count-- == 1)
+ {
mysql_mutex_unlock(&LOCK_open);
+ mysql_mutex_lock(&LOCK_dd_owns_lock_open);
+ --dd_owns_lock_open;
+ mysql_mutex_unlock(&LOCK_dd_owns_lock_open);
+ }
return result;
}
Attachment: [text/bzr-bundle] bzr/bjorn.munch@oracle.com-20100920082439-vlseaixta0ikxvlv.bundle
| Thread |
|---|
| • bzr push into mysql-trunk-mtr branch (bjorn.munch:2967 to 2969) | Bjorn Munch | 20 Sep |