chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] tcp-connect open ports problem


From: Matt Jones
Subject: Re: [Chicken-users] tcp-connect open ports problem
Date: Mon, 06 Apr 2009 00:22:13 +0100
User-agent: Thunderbird 1.5.0.14pre (X11/20071022)

felix winkelmann wrote:
On Sun, Apr 5, 2009 at 11:29 PM, Matt Jones <address@hidden> wrote:
Kon Lovett wrote:
Versions before 3.0 are unsupported AFAIK. Packaged sources are
available at the Chicken website:
http://call-with-current-continuation.org as are instructions for
accessing the source repository.

Thanks for the tip.  I have upgraded to version 3.4.  The problem persists,
though.  I looked at the source and the relevant part is the same.  The
function 'fail appears to close the port -- (##net#close s) -- but somehow
these ports end up open and accumulate.


Is it possible that the condition-case handling somehow skips the
closing of the port? (A lame question, I know - but I don't
know what to do besides trying the code myself, for which I currently haven't
got the time)


cheers,
felix




Hm ... my quesiton is, What is the intended behavior of tcp-connect when it signals an exception after failing to connect? Is it supposed to leave a port open? That is what it appears to do.

I can't close the port when I handle the exception because I'm not in possession of it. (The exception is signalled during the call to tcp-connect, so it never returns a valid port.) That's why it seems more likely that it shouldn't be open when the exception is signalled.

(BTW, this part of my message above

>> The function 'fail appears to close the port -- (##net#close s) --
>> but somehow these ports end up open and accumulate.

refers to the code in Chicken's tcp.scm, in the definition of tcp-connect, not my code. My code isn't trying to close the port. My point there was that tcp-connect appears to close the port before signalling an exception, yet the port remains open. I realize that was probably unclear.)

Best
Matt




reply via email to

[Prev in Thread] Current Thread [Next in Thread]