summaryrefslogtreecommitdiff
path: root/sql/set_var.cc
diff options
context:
space:
mode:
authorunknown <cmiller@zippy.cornsilk.net>2007-09-10 08:06:27 -0400
committerunknown <cmiller@zippy.cornsilk.net>2007-09-10 08:06:27 -0400
commitb86904731fb41961631f4c893ef11340de0e9614 (patch)
tree778fee9432c6a68f033c652aa8b4d32b49a0e4f3 /sql/set_var.cc
parent5c836d24f64eb99aba3cb94da3ee90bcca209500 (diff)
parent4b38d1216183d12565342e0dc4551f29afb81313 (diff)
downloadmariadb-git-b86904731fb41961631f4c893ef11340de0e9614.tar.gz
Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into zippy.cornsilk.net:/home/cmiller/work/mysql/mysql-5.0-community BitKeeper/triggers/post-commit: Auto merged CMakeLists.txt: Auto merged VC++Files/sql/mysqld.vcproj: Auto merged client/CMakeLists.txt: Auto merged extra/CMakeLists.txt: Auto merged libmysql/CMakeLists.txt: Auto merged myisam/CMakeLists.txt: Auto merged myisam/mi_open.c: Auto merged mysql-test/r/information_schema.result: Auto merged mysql-test/r/information_schema_db.result: Auto merged mysql-test/t/information_schema.test: Auto merged ndb/src/common/util/File.cpp: Auto merged server-tools/instance-manager/CMakeLists.txt: Auto merged sql/CMakeLists.txt: Auto merged sql/Makefile.am: Auto merged sql/ha_archive.cc: Auto merged sql/ha_berkeley.cc: Auto merged sql/ha_myisam.cc: Auto merged sql/ha_myisammrg.cc: Auto merged sql/ha_ndbcluster.cc: Auto merged sql/item_cmpfunc.cc: Auto merged sql/item_func.cc: Auto merged sql/lock.cc: Auto merged sql/log_event.cc: Auto merged sql/mysql_priv.h: Auto merged sql/mysqld.cc: Auto merged sql/set_var.cc: Auto merged sql/slave.cc: Auto merged sql/sp_head.cc: Auto merged sql/sql_base.cc: Auto merged sql/sql_cache.cc: Auto merged sql/sql_class.cc: Auto merged sql/sql_class.h: Auto merged sql/sql_delete.cc: Auto merged sql/sql_insert.cc: Auto merged sql/sql_lex.cc: Auto merged sql/sql_lex.h: Auto merged sql/sql_prepare.cc: Auto merged sql/sql_repl.cc: Auto merged sql/sql_select.cc: Auto merged sql/sql_show.cc: Auto merged sql/sql_table.cc: Auto merged sql/sql_update.cc: Auto merged sql/sql_view.cc: Auto merged sql/sql_yacc.yy: Auto merged sql/table.h: Auto merged win/README: Auto merged win/configure.js: Auto merged configure.in: manual merge. version update. sql/sql_parse.cc: manual merge
Diffstat (limited to 'sql/set_var.cc')
-rw-r--r--sql/set_var.cc16
1 files changed, 15 insertions, 1 deletions
diff --git a/sql/set_var.cc b/sql/set_var.cc
index e1246617d84..1c91fb9cbca 100644
--- a/sql/set_var.cc
+++ b/sql/set_var.cc
@@ -546,6 +546,12 @@ static sys_var_thd_bit sys_unique_checks("unique_checks", 0,
set_option_bit,
OPTION_RELAXED_UNIQUE_CHECKS,
1);
+#ifdef ENABLED_PROFILING
+static sys_var_thd_bit sys_profiling("profiling", NULL, set_option_bit,
+ ulonglong(OPTION_PROFILING));
+static sys_var_thd_ulong sys_profiling_history_size("profiling_history_size",
+ &SV::profiling_history_size);
+#endif
/* Local state variables */
@@ -707,6 +713,10 @@ sys_var *sys_variables[]=
&sys_optimizer_prune_level,
&sys_optimizer_search_depth,
&sys_preload_buff_size,
+#ifdef ENABLED_PROFILING
+ &sys_profiling,
+ &sys_profiling_history_size,
+#endif
&sys_pseudo_thread_id,
&sys_query_alloc_block_size,
&sys_query_cache_size,
@@ -1021,6 +1031,10 @@ struct show_var_st init_vars[]= {
{"pid_file", (char*) pidfile_name, SHOW_CHAR},
{"port", (char*) &mysqld_port, SHOW_INT},
{sys_preload_buff_size.name, (char*) &sys_preload_buff_size, SHOW_SYS},
+#ifdef ENABLED_PROFILING
+ {sys_profiling.name, (char*) &sys_profiling, SHOW_SYS},
+ {sys_profiling_history_size.name, (char*) &sys_profiling_history_size, SHOW_SYS},
+#endif
{"protocol_version", (char*) &protocol_version, SHOW_INT},
{sys_query_alloc_block_size.name, (char*) &sys_query_alloc_block_size,
SHOW_SYS},
@@ -2900,7 +2914,7 @@ static bool set_option_autocommit(THD *thd, set_var *var)
if ((org_options & OPTION_NOT_AUTOCOMMIT))
{
/* We changed to auto_commit mode */
- thd->options&= ~(ulong) OPTION_BEGIN;
+ thd->options&= ~OPTION_BEGIN;
thd->transaction.all.modified_non_trans_table= FALSE;
thd->server_status|= SERVER_STATUS_AUTOCOMMIT;
if (ha_commit(thd))