Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion ext/ftp/ftp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1471,7 +1471,8 @@ static int my_poll(php_socket_t fd, int events, int timeout) {

if (n == -1 && php_socket_errno() == EINTR) {
zend_hrtime_t delta_ns = zend_hrtime() - start_ns;
if (delta_ns > timeout_hr) {
/* delta_ns == 0 is only possible with a platform that does not support a high-res timer. */
if (delta_ns > timeout_hr || UNEXPECTED(delta_ns == 0)) {
#ifndef PHP_WIN32
errno = ETIMEDOUT;
#endif
Expand Down
Loading