Skip to content

Commit 5d0a43a

Browse files
committed
Update the document for epoll.poll in select.rst
1 parent 23ad9c5 commit 5d0a43a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Doc/library/select.rst

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,10 +375,16 @@ Edge and Level Trigger Polling (epoll) Objects
375375

376376
.. method:: epoll.poll(timeout=None, maxevents=-1)
377377

378-
Wait for events.
378+
Wait for events. Return a list of ``(fd, eventmask)`` tuples if there's any
379+
event. Otherwise, an empty list is returned. See the :ref:`epoll-objects`
380+
section above for the event constants.
381+
379382
If *timeout* is given, it specifies the length of time in seconds
380383
(may be non-integer) which the system will wait for events before returning.
381384

385+
*maxevents* specifies the maximum number of events to return. It must be
386+
greater than 0, or ``-1`` to use the default (``FD_SETSIZE-1``).
387+
382388
.. versionchanged:: 3.5
383389
The function is now retried with a recomputed timeout when interrupted by
384390
a signal, except if the signal handler raises an exception (see

0 commit comments

Comments
 (0)