You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by rp...@apache.org on 2009/10/06 21:01:45 UTC

svn commit: r822431 - /apr/apr/trunk/include/apr_network_io.h

Author: rpluem
Date: Tue Oct  6 19:01:45 2009
New Revision: 822431

URL: http://svn.apache.org/viewvc?rev=822431&view=rev
Log:
* Improve the documentation

Suggested by: jorton

Modified:
    apr/apr/trunk/include/apr_network_io.h

Modified: apr/apr/trunk/include/apr_network_io.h
URL: http://svn.apache.org/viewvc/apr/apr/trunk/include/apr_network_io.h?rev=822431&r1=822430&r2=822431&view=diff
==============================================================================
--- apr/apr/trunk/include/apr_network_io.h (original)
+++ apr/apr/trunk/include/apr_network_io.h Tue Oct  6 19:01:45 2009
@@ -375,8 +375,15 @@
                                              apr_sockaddr_t *sa);
 
 /**
- * Check whether the remote side of a socket is still open.
+ * Check whether the receive part of the socket has been shut down by the
+ * peer and that the socket's read buffer is empty. If this is true the next
+ * read on the socket wil return APR_EOF.
  * @param socket The socket to check
+ * @remark
+ * <PRE>
+ * This function does not block on the socket but returns immediately in
+ * any case.
+ * </PRE>
  */
 APR_DECLARE(int) apr_socket_is_connected(apr_socket_t *socket);
 



Re: svn commit: r822431 - /apr/apr/trunk/include/apr_network_io.h

Posted by Jim Jagielski <ji...@jaguNET.com>.
Lovely!
On Oct 7, 2009, at 3:00 PM, Ruediger Pluem wrote:

>
>
> On 10/07/2009 06:44 PM, Jim Jagielski wrote:
>> This is still confusing... "if true, then the next
>> read will return APR_EOF" but doesn't it return true if
>> there is still stuff to read?
>>
>> How about "Check whether the receive part of the socket is
>> still connected and not shutdown by...."
>
> Good catch. I let myself confuse from the mail.
>
> How about:
>
> * Check whether the send part of the socket is still open on the
> * peer or that there is still data in the socket's read buffer.
> * If this is false the next read on the socket will return APR_EOF.
>
>
> Regards
>
> RĂ¼diger
>


Re: svn commit: r822431 - /apr/apr/trunk/include/apr_network_io.h

Posted by Ruediger Pluem <rp...@apache.org>.

On 10/07/2009 06:44 PM, Jim Jagielski wrote:
> This is still confusing... "if true, then the next
> read will return APR_EOF" but doesn't it return true if
> there is still stuff to read?
> 
> How about "Check whether the receive part of the socket is
> still connected and not shutdown by...."

Good catch. I let myself confuse from the mail.

How about:

* Check whether the send part of the socket is still open on the
* peer or that there is still data in the socket's read buffer.
* If this is false the next read on the socket will return APR_EOF.


Regards

RĂ¼diger


Re: svn commit: r822431 - /apr/apr/trunk/include/apr_network_io.h

Posted by Jim Jagielski <ji...@jaguNET.com>.
This is still confusing... "if true, then the next
read will return APR_EOF" but doesn't it return true if
there is still stuff to read?

How about "Check whether the receive part of the socket is
still connected and not shutdown by...."

On Oct 6, 2009, at 3:01 PM, rpluem@apache.org wrote:

> Author: rpluem
> Date: Tue Oct  6 19:01:45 2009
> New Revision: 822431
>
> URL: http://svn.apache.org/viewvc?rev=822431&view=rev
> Log:
> * Improve the documentation
>
> Suggested by: jorton
>
> Modified:
>    apr/apr/trunk/include/apr_network_io.h
>
> Modified: apr/apr/trunk/include/apr_network_io.h
> URL: http://svn.apache.org/viewvc/apr/apr/trunk/include/apr_network_io.h?rev=822431&r1=822430&r2=822431&view=diff
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- apr/apr/trunk/include/apr_network_io.h (original)
> +++ apr/apr/trunk/include/apr_network_io.h Tue Oct  6 19:01:45 2009
> @@ -375,8 +375,15 @@
>                                              apr_sockaddr_t *sa);
>
> /**
> - * Check whether the remote side of a socket is still open.
> + * Check whether the receive part of the socket has been shut down  
> by the
> + * peer and that the socket's read buffer is empty. If this is true  
> the next
> + * read on the socket wil return APR_EOF.
>  * @param socket The socket to check
> + * @remark
> + * <PRE>
> + * This function does not block on the socket but returns  
> immediately in
> + * any case.
> + * </PRE>
>  */
> APR_DECLARE(int) apr_socket_is_connected(apr_socket_t *socket);
>
>
>