summaryrefslogtreecommitdiff
path: root/sql/set_var.cc
diff options
context:
space:
mode:
Diffstat (limited to 'sql/set_var.cc')
-rw-r--r--sql/set_var.cc29
1 files changed, 16 insertions, 13 deletions
diff --git a/sql/set_var.cc b/sql/set_var.cc
index dd30d2e377d..66aded8422f 100644
--- a/sql/set_var.cc
+++ b/sql/set_var.cc
@@ -206,7 +206,7 @@ sys_var_thd_enum sys_query_cache_type("query_cache_type",
sys_var_long_ptr sys_server_id("server_id",&server_id);
sys_var_bool_ptr sys_slave_compressed_protocol("slave_compressed_protocol",
&opt_slave_compressed_protocol);
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
sys_var_long_ptr sys_slave_net_timeout("slave_net_timeout",
&slave_net_timeout);
#endif
@@ -299,7 +299,7 @@ static sys_var_readonly sys_warning_count("warning_count",
get_warning_count);
/* alias for last_insert_id() to be compatible with Sybase */
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
static sys_var_slave_skip_counter sys_slave_skip_counter("sql_slave_skip_counter");
#endif
static sys_var_rand_seed1 sys_rand_seed1("rand_seed1");
@@ -383,7 +383,7 @@ sys_var *sys_variables[]=
&sys_safe_updates,
&sys_select_limit,
&sys_server_id,
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
&sys_slave_compressed_protocol,
&sys_slave_net_timeout,
&sys_slave_skip_counter,
@@ -480,7 +480,7 @@ struct show_var_st init_vars[]= {
{"log", (char*) &opt_log, SHOW_BOOL},
{"log_update", (char*) &opt_update_log, SHOW_BOOL},
{"log_bin", (char*) &opt_bin_log, SHOW_BOOL},
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
{"log_slave_updates", (char*) &opt_log_slave_updates, SHOW_MY_BOOL},
#endif
{"log_slow_queries", (char*) &opt_slow_log, SHOW_BOOL},
@@ -534,7 +534,7 @@ struct show_var_st init_vars[]= {
{"shared_memory_base_name", (char*) &shared_memory_base_name, SHOW_CHAR_PTR},
#endif
{sys_server_id.name, (char*) &sys_server_id, SHOW_SYS},
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
{sys_slave_net_timeout.name,(char*) &sys_slave_net_timeout, SHOW_SYS},
#endif
{"skip_external_locking", (char*) &my_disable_locking, SHOW_MY_BOOL},
@@ -636,7 +636,7 @@ static void fix_tx_isolation(THD *thd, enum_var_type type)
If we are changing the thread variable, we have to copy it to NET too
*/
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
static void fix_net_read_timeout(THD *thd, enum_var_type type)
{
if (type != OPT_GLOBAL)
@@ -655,14 +655,17 @@ static void fix_net_retry_count(THD *thd, enum_var_type type)
if (type != OPT_GLOBAL)
thd->net.retry_count=thd->variables.net_retry_count;
}
-#else /* EMBEDDED_LIBRARY */
-static void fix_net_read_timeout(THD *thd __attribute__(unused), enum_var_type type __attribute__(unused))
+#else /* HAVE_REPLICATION */
+static void fix_net_read_timeout(THD *thd __attribute__(unused),
+ enum_var_type type __attribute__(unused))
{}
-static void fix_net_write_timeout(THD *thd __attribute__(unused), enum_var_type type __attribute__(unused))
+static void fix_net_write_timeout(THD *thd __attribute__(unused),
+ enum_var_type type __attribute__(unused))
{}
-static void fix_net_retry_count(THD *thd __attribute__(unused), enum_var_type type __attribute__(unused))
+static void fix_net_retry_count(THD *thd __attribute__(unused),
+ enum_var_type type __attribute__(unused))
{}
-#endif /* EMBEDDED_LIBRARY */
+#endif /* HAVE_REPLICATION */
static void fix_query_cache_size(THD *thd, enum_var_type type)
@@ -1079,7 +1082,7 @@ byte *sys_var_insert_id::value_ptr(THD *thd, enum_var_type type)
}
-#ifndef EMBEDDED_LIBRARY
+#ifdef HAVE_REPLICATION
bool sys_var_slave_skip_counter::check(THD *thd, set_var *var)
{
int result= 0;
@@ -1115,7 +1118,7 @@ bool sys_var_slave_skip_counter::update(THD *thd, set_var *var)
UNLOCK_ACTIVE_MI;
return 0;
}
-#endif /* EMBEDDED_LIBRARY */
+#endif /* HAVE_REPLICATION */
bool sys_var_rand_seed1::update(THD *thd, set_var *var)
{