Bugzilla bug #17806: improved comments for PR_Poll.
authorwtc%netscape.com
Sat, 10 Jun 2000 00:43:59 +0000
changeset 1421 b55d48e4c56babd443bc2aed69f09e3df6bd58ab
parent 1420 0a18935b05b38a1efcbe50bd82abe573f3ab9689
child 1422 f7355e07ba7f7b3532074c5d7f4fc7095d3d292f
push idunknown
push userunknown
push dateunknown
bugs17806
Bugzilla bug #17806: improved comments for PR_Poll.
pr/include/prio.h
--- a/pr/include/prio.h
+++ b/pr/include/prio.h
@@ -1865,17 +1865,20 @@ struct PRPollDesc {
 **
 ** The call returns as soon as I/O is ready on one or more of the underlying
 ** file/socket objects. A count of the number of ready descriptors is
 ** returned unless a timeout occurs in which case zero is returned.
 **
 ** PRPollDesc.in_flags should be set to the desired request
 ** (read/write/except or some combination). Upon successful return from
 ** this call PRPollDesc.out_flags will be set to indicate what kind of
-** i/o can be performed on the respective descriptor.
+** i/o can be performed on the respective descriptor. PR_Poll() uses the
+** out_flags fields as scratch variables during the call. If PR_Poll()
+** returns 0 or -1, the out_flags fields do not contain meaningful values
+** and must not be used.
 **
 ** INPUTS:
 **      PRPollDesc *pds         A pointer to an array of PRPollDesc
 **
 **      PRIntn npds             The number of elements in the array
 **                              If this argument is zero PR_Poll is
 **                              equivalent to a PR_Sleep(timeout).
 **
@@ -1884,21 +1887,17 @@ struct PRPollDesc {
 **                              w/o any I/O becoming ready, the result will
 **                              be zero.
 **
 ** OUTPUTS:    None
 ** RETURN:
 **      PRInt32                 Number of PRPollDesc's with events or zero
 **                              if the function timed out or -1 on failure.
 **                              The reason for the failure is obtained by
-**                              calling PR_GetError().  PR_Poll() uses the
-**                              out_flags fields as scratch variables
-**                              during the call.  If PR_Poll() returns 0
-**                              or -1, the out_flags fields do not contain
-**                              meaningful values and must not be used.
+**                              calling PR_GetError().
 **************************************************************************
 */
 NSPR_API(PRInt32) PR_Poll(
     PRPollDesc *pds, PRIntn npds, PRIntervalTime timeout);
 
 /*
 **************************************************************************
 **