summaryrefslogtreecommitdiff
path: root/poll
diff options
context:
space:
mode:
authorJeff Trawick <trawick@apache.org>2009-11-09 16:37:50 +0000
committerJeff Trawick <trawick@apache.org>2009-11-09 16:37:50 +0000
commit77d8f6f0c73bccf69b57adfae6d5169ee667f0f2 (patch)
tree13fd35a2ba29c2f3820bda999ba4628242b72d48 /poll
parenta84b60e5ccc19de47c6a8e3ee388d722fa99ef1f (diff)
downloadapr-77d8f6f0c73bccf69b57adfae6d5169ee667f0f2.tar.gz
fix pollcb hangs on Solaris when using Event Ports
passing nget=n will block until n events are available (or timeout/signal occurs) possible future optimization: in order to retrieve 1 or more events, first call port_getn() with nget=0 to find out how many events are available, then call it again with the number available git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@834136 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'poll')
-rw-r--r--poll/unix/port.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/poll/unix/port.c b/poll/unix/port.c
index 1d2613df1..a4509ac8a 100644
--- a/poll/unix/port.c
+++ b/poll/unix/port.c
@@ -537,7 +537,7 @@ static apr_status_t impl_pollcb_poll(apr_pollcb_t *pollcb,
{
apr_pollfd_t *pollfd;
apr_status_t rv;
- unsigned int i, nget = pollcb->nalloc;
+ unsigned int i, nget = 1;
rv = call_port_getn(pollcb->fd, pollcb->pollset.port, pollcb->nalloc,
&nget, timeout);