From 26f249f6db8098f161e19a08930d3c227281ea9a Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Thu, 23 Jul 2015 10:55:24 +0200 Subject: [PATCH] compilation failures on Windows --- include/mysql/psi/mysql_socket.h | 4 ++++ sql/wsrep_xid.h | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/include/mysql/psi/mysql_socket.h b/include/mysql/psi/mysql_socket.h index 6f37e012f1f..33768b20fa8 100644 --- a/include/mysql/psi/mysql_socket.h +++ b/include/mysql/psi/mysql_socket.h @@ -1033,11 +1033,13 @@ inline_mysql_socket_accept SOCK_CLOEXEC); #else socket_accept.fd= accept(socket_listen.fd, addr, &addr_length); +#ifdef FD_CLOEXEC flags= fcntl(socket_accept.fd, F_GETFD); if (flags != -1) { flags |= FD_CLOEXEC; fcntl(socket_accept.fd, F_SETFD, flags); } +#endif #endif /* Instrumentation end */ @@ -1053,11 +1055,13 @@ inline_mysql_socket_accept SOCK_CLOEXEC); #else socket_accept.fd= accept(socket_listen.fd, addr, &addr_length); +#ifdef FD_CLOEXEC flags= fcntl(socket_accept.fd, F_GETFD); if (flags != -1) { flags |= FD_CLOEXEC; fcntl(socket_accept.fd, F_SETFD, flags); } +#endif #endif } diff --git a/sql/wsrep_xid.h b/sql/wsrep_xid.h index 7bd2b063b48..c3cad0231d7 100644 --- a/sql/wsrep_xid.h +++ b/sql/wsrep_xid.h @@ -17,11 +17,12 @@ #define WSREP_XID_H #include -#include "../wsrep/wsrep_api.h" -#include "handler.h" // XID typedef #ifdef WITH_WSREP +#include "../wsrep/wsrep_api.h" +#include "handler.h" // XID typedef + void wsrep_xid_init(xid_t*, const wsrep_uuid_t&, wsrep_seqno_t); const wsrep_uuid_t* wsrep_xid_uuid(const XID&); wsrep_seqno_t wsrep_xid_seqno(const XID&);