svn commit: r194672 - in head/sys: kern netinet sys
Andre Oppermann
andre at freebsd.org
Mon Jun 29 07:24:15 UTC 2009
Christoph Mallon wrote:
> Andre Oppermann schrieb:
>> Author: andre
>> Date: Mon Jun 22 23:08:05 2009
>> New Revision: 194672
>> URL: http://svn.freebsd.org/changeset/base/194672
>>
>> Log:
>> Add soreceive_stream(), an optimized version of soreceive() for
>> stream (TCP) sockets.
> [...]
>> Modified: head/sys/kern/uipc_socket.c
>> ==============================================================================
>>
>> --- head/sys/kern/uipc_socket.c Mon Jun 22 22:54:44 2009 (r194671)
>> +++ head/sys/kern/uipc_socket.c Mon Jun 22 23:08:05 2009 (r194672)
>> @@ -1857,6 +1857,202 @@ release:
> [...]
>> + /* We will never ever get anything unless we are connected. */
>> + if (!(so->so_state & (SS_ISCONNECTED|SS_ISDISCONNECTED))) {
>> + /* When disconnecting there may be still some data left. */
>> + if (sb->sb_cc > 0)
>> + goto deliver;
>> + if (!(so->so_state & SS_ISDISCONNECTED))
>> + error = ENOTCONN;
>> + goto out;
>> + }
>
> It seems either the third "if" is redundant (because the condition of
> first "if" implies the condition of the third) or one of the conditions
> is wrong.
> Also there should be spaces around the |.
Thank you for the report. I'm working on fixing and testing all the issues
that were raised in the perforce branch to be committed soon after review.
--
Andre
More information about the svn-src-head
mailing list