summaryrefslogtreecommitdiff
path: root/sql/wsrep_utils.cc
diff options
context:
space:
mode:
authorSeppo Jaakola <seppo.jaakola@codership.com>2013-08-07 00:17:16 +0300
committerSeppo Jaakola <seppo.jaakola@codership.com>2013-08-07 00:17:16 +0300
commit551ad1cf6f80ad1fab35746eee304d733baa9adf (patch)
tree120046ba39eaa403a7b9c0d3de0a03b5de0c1bbb /sql/wsrep_utils.cc
parent7cf10ddf8ca7044278b4aa1cf5a5525675cd101d (diff)
downloadmariadb-git-551ad1cf6f80ad1fab35746eee304d733baa9adf.tar.gz
Merged FreeBSD compatibility changes (up to revision 3893 in lp:~codership/codership-mysql/5.5-23)
Diffstat (limited to 'sql/wsrep_utils.cc')
-rw-r--r--sql/wsrep_utils.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/wsrep_utils.cc b/sql/wsrep_utils.cc
index 392fb65d82c..19ffb101841 100644
--- a/sql/wsrep_utils.cc
+++ b/sql/wsrep_utils.cc
@@ -358,6 +358,8 @@ size_t guess_ip (char* buf, size_t buf_len)
#elif defined(__sun__)
const char cmd[] = "/sbin/ifconfig -a | "
"/usr/gnu/bin/grep -m1 -1 -E 'net[0-9]:' | tail -n 1 | awk '{ print $2 }'";
+#elif defined(__APPLE__) || defined(__FreeBSD__)
+ const char cmd[] = "route -nv get 8.8.8.8 | tail -n1 | awk '{print $5}'";
#else
char *cmd;
#error "OS not supported"