Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 25 Jan 2009 11:57:38 -0800
From:      Sam Leffler <sam@freebsd.org>
To:        Jeff Roberson <jeff@freebsd.org>
Cc:        svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org
Subject:   Re: svn commit: r187677 - head/sys/kern
Message-ID:  <497CC432.5010303@freebsd.org>
In-Reply-To: <200901250724.n0P7OYd9009645@svn.freebsd.org>
References:  <200901250724.n0P7OYd9009645@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Jeff Roberson wrote:
> Author: jeff
> Date: Sun Jan 25 07:24:34 2009
> New Revision: 187677
> URL: http://svn.freebsd.org/changeset/base/187677
>
> Log:
>   Fix errors introduced when I rewrote select.
>    - Restructure selscan() and selrescan() to avoid producing extra selfps
>      when we have a fd in multiple sets.  As described below multiple selfps
>      may still exist for other reasons.
>    - Make selrescan() tolerate multiple selfds for a given descriptor
>      set since sockets use two selinfos per fd.  If an event on each selinfo
>      fires selrescan() will see the descriptor twice.  This could result in
>      select() returning 2x the number of fds actually existing in fd sets.
>   
>   

Can you clarify what the erroneous behaviour is?  It appears the caller 
will receive nfds set to 2x the actual number of descriptors marked in 
the bit vectors?  Was this identified because an application 
failed/misbehaved?  If so, and the application is public please identify it.

    Sam




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?497CC432.5010303>