summaryrefslogtreecommitdiff
path: root/include/mysql
diff options
context:
space:
mode:
authorVicențiu Ciorbaru <vicentiu@mariadb.org>2018-06-12 19:39:37 +0300
committerVicențiu Ciorbaru <vicentiu@mariadb.org>2018-06-12 19:39:37 +0300
commit6e55236c0a72e8f49a240c4e080591994042b0e4 (patch)
tree4bb2f438004db3dbba5f88f5e4b00aacfd5c1cec /include/mysql
parentaa59ecec89d89a29f7272352471a4064aa6db28c (diff)
parent215d652c66474c4578b0476385d055e7feae2d3a (diff)
downloadmariadb-git-6e55236c0a72e8f49a240c4e080591994042b0e4.tar.gz
Merge branch '10.0-galera' into 10.1
Diffstat (limited to 'include/mysql')
-rw-r--r--include/mysql/psi/mysql_socket.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/mysql/psi/mysql_socket.h b/include/mysql/psi/mysql_socket.h
index 1dbe8c7eb22..fc0a3ce2eb0 100644
--- a/include/mysql/psi/mysql_socket.h
+++ b/include/mysql/psi/mysql_socket.h
@@ -562,6 +562,12 @@ inline_mysql_socket_socket
(key, (const my_socket*)&mysql_socket.fd, NULL, 0);
}
#endif
+
+ /* SOCK_CLOEXEC isn't always a number - can't preprocessor compare */
+#if defined(HAVE_FCNTL) && defined(FD_CLOEXEC) && !defined(HAVE_SOCK_CLOEXEC)
+ (void) fcntl(mysql_socket.fd, F_SETFD, FD_CLOEXEC);
+#endif
+
return mysql_socket;
}