You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by mt...@apache.org on 2009/02/15 09:05:06 UTC

svn commit: r744625 - in /apr/apr/trunk/poll/unix: pollcb.c pollset.c

Author: mturk
Date: Sun Feb 15 08:05:05 2009
New Revision: 744625

URL: http://svn.apache.org/viewvc?rev=744625&view=rev
Log:
Add few comments on WSAPoll runtime usage

Modified:
    apr/apr/trunk/poll/unix/pollcb.c
    apr/apr/trunk/poll/unix/pollset.c

Modified: apr/apr/trunk/poll/unix/pollcb.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/poll/unix/pollcb.c?rev=744625&r1=744624&r2=744625&view=diff
==============================================================================
--- apr/apr/trunk/poll/unix/pollcb.c (original)
+++ apr/apr/trunk/poll/unix/pollcb.c Sun Feb 15 08:05:05 2009
@@ -130,8 +130,13 @@
 {
     apr_pollset_method_e method = APR_POLLSET_DEFAULT;
  #ifdef WIN32
+    /* This will work only if ws2_32.dll has WSAPoll funtion.
+     * We could check the presence of the function here,
+     * but someone might implement other pollcb method in
+     * the future.
+     */
     method = APR_POLLSET_POLL;
- #endif       
+ #endif
     return apr_pollcb_create_ex(pollcb, size, p, flags, method);
 }
 

Modified: apr/apr/trunk/poll/unix/pollset.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/poll/unix/pollset.c?rev=744625&r1=744624&r2=744625&view=diff
==============================================================================
--- apr/apr/trunk/poll/unix/pollset.c (original)
+++ apr/apr/trunk/poll/unix/pollset.c Sun Feb 15 08:05:05 2009
@@ -275,8 +275,13 @@
 {
     apr_pollset_method_e method = APR_POLLSET_DEFAULT;
  #ifdef WIN32
+    /* Favor WSAPoll if supported.
+     * This will work only if ws2_32.dll has WSAPoll funtion.
+     * In other cases it will fall back to select() method unless
+     * the APR_POLLSET_NODEFAULT is added to the flags.
+     */
     method = APR_POLLSET_POLL;
- #endif   
+ #endif
     return apr_pollset_create_ex(pollset, size, p, flags, method);
 }