[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] zmq, problems with using several sockets, closing so
From: |
.alyn.post. |
Subject: |
Re: [Chicken-users] zmq, problems with using several sockets, closing sockets |
Date: |
Tue, 6 Nov 2012 08:16:40 -0701 |
On Tue, Nov 06, 2012 at 06:48:33AM -0700, matt welland wrote:
> > I guess this could be considered a bug: The finalizer unconditionally
> > closes the socket which seems to lead to this error when it was
> > explicitly closed before. Skimming the API reference I don't see a way
> > to check whether a socket is already closed. Do you know of any? Or do
> > you have a better idea how to handle this situation?
>
> I also could not find a way to check that a socket was already closed.
> As a last resort perhaps add a flag to disable finalizers?
>
Can you call getsockopt with the SO_TYPE flag and check for EBADF
and ENOTSOCK? That is essentially why the finalizer is 'failing'
anyway...
-Alan
--
.i ma'a lo bradi cu penmi gi'e du
- [Chicken-users] zmq, problems with using several sockets, closing sockets, Matt Welland, 2012/11/01
- Re: [Chicken-users] zmq, problems with using several sockets, closing sockets, Moritz Heidkamp, 2012/11/05
- Re: [Chicken-users] zmq, problems with using several sockets, closing sockets, Thomas Hintz, 2012/11/05
- Re: [Chicken-users] zmq, problems with using several sockets, closing sockets, matt welland, 2012/11/06
- Re: [Chicken-users] zmq, problems with using several sockets, closing sockets,
.alyn.post. <=