summaryrefslogtreecommitdiff
path: root/sql/sys_vars.cc
diff options
context:
space:
mode:
authorAlexander Nozdrin <alexander.nozdrin@oracle.com>2012-04-27 19:14:28 +0400
committerAlexander Nozdrin <alexander.nozdrin@oracle.com>2012-04-27 19:14:28 +0400
commit3885dc55ddf494e6917f30aa7bd638d0fd63811f (patch)
treeb3ee0b8979d0ccfdea52af32f5bb363efa56ad8d /sql/sys_vars.cc
parentcb4490919ba28b5b88044de78f27617a930db386 (diff)
downloadmariadb-git-3885dc55ddf494e6917f30aa7bd638d0fd63811f.tar.gz
Proper follow-up for Bug#12762885 - 61713: MYSQL WILL NOT BIND TO "LOCALHOST"
IF LOCALHOST IS BOTH IPV4/IPV6 ENABLED. The original patch removed default value of the bind-address option. So, the default value became NULL. By coincedence NULL resolves to 0.0.0.0 and ::, and since the server chooses first IPv4-address, 0.0.0.0 is choosen. So, there was no change in the behaviour. This patch restores default value of the bind-address option to "0.0.0.0".
Diffstat (limited to 'sql/sys_vars.cc')
-rw-r--r--sql/sys_vars.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/sql/sys_vars.cc b/sql/sys_vars.cc
index f15664bca10..9c7421c46f2 100644
--- a/sql/sys_vars.cc
+++ b/sql/sys_vars.cc
@@ -308,6 +308,11 @@ static Sys_var_charptr Sys_basedir(
READ_ONLY GLOBAL_VAR(mysql_home_ptr), CMD_LINE(REQUIRED_ARG, 'b'),
IN_FS_CHARSET, DEFAULT(0));
+static Sys_var_charptr Sys_my_bind_addr(
+ "bind_address", "IP address to bind to.",
+ READ_ONLY GLOBAL_VAR(my_bind_addr_str), CMD_LINE(REQUIRED_ARG),
+ IN_FS_CHARSET, DEFAULT("0.0.0.0"));
+
static Sys_var_ulong Sys_binlog_cache_size(
"binlog_cache_size", "The size of the transactional cache for "
"updates to transactional engines for the binary log. "