Skip to content

Commit 9622a3b

Browse files
committedApr 30, 2017
Merge branch 'PHP-7.0' into PHP-7.1
2 parents 6028fe5 + d9dfac9 commit 9622a3b

File tree

4 files changed

+14
-5
lines changed

4 files changed

+14
-5
lines changed
 

‎configure.in

+1
Original file line numberDiff line numberDiff line change
@@ -494,6 +494,7 @@ limits.h \
494494
locale.h \
495495
monetary.h \
496496
netdb.h \
497+
poll.h \
497498
pwd.h \
498499
resolv.h \
499500
signal.h \

‎main/fastcgi.c

+4-2
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,9 @@ static int is_impersonate = 0;
7676
# include <netdb.h>
7777
# include <signal.h>
7878

79-
# if defined(HAVE_SYS_POLL_H) && defined(HAVE_POLL)
79+
# if defined(HAVE_POLL_H) && defined(HAVE_POLL)
80+
# include <poll.h>
81+
# elif defined(HAVE_SYS_POLL_H) && defined(HAVE_POLL)
8082
# include <sys/poll.h>
8183
# endif
8284
# if defined(HAVE_SYS_SELECT_H)
@@ -1430,7 +1432,7 @@ int fcgi_accept_request(fcgi_request *req)
14301432
break;
14311433
#else
14321434
if (req->fd >= 0) {
1433-
#if defined(HAVE_SYS_POLL_H) && defined(HAVE_POLL)
1435+
#if defined(HAVE_POLL)
14341436
struct pollfd fds;
14351437
int ret;
14361438

‎main/network.c

+3-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@
5151
#ifdef HAVE_SYS_SELECT_H
5252
#include <sys/select.h>
5353
#endif
54-
#if HAVE_SYS_POLL_H
54+
#if HAVE_POLL_H
55+
#include <poll.h>
56+
#elif HAVE_SYS_POLL_H
5557
#include <sys/poll.h>
5658
#endif
5759

‎main/php_network.h

+6-2
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,12 @@ typedef int php_socket_t;
122122
/* uncomment this to debug poll(2) emulation on systems that have poll(2) */
123123
/* #define PHP_USE_POLL_2_EMULATION 1 */
124124

125-
#if defined(HAVE_SYS_POLL_H) && defined(HAVE_POLL)
126-
# include <poll.h>
125+
#if defined(HAVE_POLL)
126+
# if defined(HAVE_POLL_H)
127+
# include <poll.h>
128+
# elif defined(HAVE_SYS_POLL_H)
129+
# include <sys/poll.h>
130+
# endif
127131
typedef struct pollfd php_pollfd;
128132
#else
129133
typedef struct _php_pollfd {

0 commit comments

Comments
 (0)
Please sign in to comment.