Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 7 Mar 2007 17:09:31 +0200
From:      "Vlad GALU" <dudu@dudu.ro>
To:        freebsd-net@freebsd.org
Subject:   Re: SO_ACCEPTCONN equivalent
Message-ID:  <ad79ad6b0703070709m35b2f019s4bcf02a48b11d6cd@mail.gmail.com>
In-Reply-To: <1173273861.4982.8.camel@aarion>
References:  <1173273861.4982.8.camel@aarion>

next in thread | previous in thread | raw e-mail | index | archive | help
On 3/7/07, Alexandru Arion <aarion@bitdefender.com> wrote:
> Hi,
>
> I'm rather new here, so excuses in advance if the question is out of
> topic.
>
> Is there an equivalent in FreeBSD to the SO_ACCEPTCONN option for
> getsockopt(), available in Linux? It doesn't actually has to be an
> option for getsockopt(), just a way to determine if a socket has been
> marked to accept connections with listen().

  You can accept() on that socket, which should return EINVAL if the
socket wasn't previously passed as an argument to listen(). For the
afirmative case, make sure you use non-blocking sockets, otherwise
accept() will block.

>
> Thank you,
> Alex Arion
>
>
> _______________________________________________
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"
>


-- 
If it's there, and you can see it, it's real.
If it's not there, and you can see it, it's virtual.
If it's there, and you can't see it, it's transparent.
If it's not there, and you can't see it, you erased it.



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