summaryrefslogtreecommitdiff
path: root/sql/udf_example.c
diff options
context:
space:
mode:
Diffstat (limited to 'sql/udf_example.c')
-rw-r--r--sql/udf_example.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/udf_example.c b/sql/udf_example.c
index 30d85d95034..96b7da525dc 100644
--- a/sql/udf_example.c
+++ b/sql/udf_example.c
@@ -139,7 +139,9 @@ typedef long long longlong;
#include <mysql.h>
#include <ctype.h>
+#if !defined(HAVE_GETHOSTBYADDR_R) || !defined(HAVE_SOLARIS_STYLE_GETHOST)
static pthread_mutex_t LOCK_hostname;
+#endif
#ifdef HAVE_DLOPEN