Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:michals
ruby2.7
0005-io-make-use-of-poll-POLLERR-flag.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0005-io-make-use-of-poll-POLLERR-flag.patch of Package ruby2.7
From 51f310a8e36d6607435cb70826e4378f537c15c1 Mon Sep 17 00:00:00 2001 From: Michal Suchanek <msuchanek@suse.de> Date: Mon, 3 Feb 2020 19:51:55 +0100 Subject: [PATCH 05/12] io: make use of poll POLLERR flag Return additional array of fds with error. Signed-off-by: Michal Suchanek <msuchanek@suse.de> --- include/ruby/io.h | 2 ++ thread.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/include/ruby/io.h b/include/ruby/io.h index 152f4ef7637f..978fec62c011 100644 --- a/include/ruby/io.h +++ b/include/ruby/io.h @@ -47,10 +47,12 @@ extern "C" { # define RB_WAITFD_IN POLLIN # define RB_WAITFD_PRI POLLPRI # define RB_WAITFD_OUT POLLOUT +# define RB_WAITFD_ERR (POLLHUP|POLLERR) #else # define RB_WAITFD_IN 0x001 # define RB_WAITFD_PRI 0x002 # define RB_WAITFD_OUT 0x004 +# define RB_WAITFD_ERR 0x008 #endif RUBY_SYMBOL_EXPORT_BEGIN diff --git a/thread.c b/thread.c index b865ed84f860..e5d2ba0a2019 100644 --- a/thread.c +++ b/thread.c @@ -4305,7 +4305,7 @@ rb_wait_for_single_fd(int fd, int events, struct timeval *timeout) /* all requested events are ready if there is an error */ if (fds[0].revents & POLLERR_SET) - result |= events; + result |= events | POLLERR_SET; return result; } -- 2.26.2
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor