|
From: | Kon Lovett |
Subject: | Re: [Chicken-users] tcp-connect open ports problem |
Date: | Sun, 5 Apr 2009 08:28:30 -0700 |
On Apr 5, 2009, at 7:03 AM, Matt Jones wrote:
Hi folks,I'm having an issue with the tcp-connect function. When it fails to connect, it seems not to clean up properly, so that I end up with lots of open ports.Try this code: (require-extension tcp) (define (error-info e) ((condition-property-accessor 'exn 'message) e)) (define (test-tcp-connect) (condition-case (tcp-connect "localhost" 8000) (e (exn i/o net) (print (error-info e))))) assuming there is nothing on port 8000. Then,(let loop ((i 0)) (when (< i 2000) (test-tcp-connect) (loop (+ i 1))))I get, can not create socket - Connection refused can not create socket - Connection refused ... can not create socket - Too many open files can not create socket - Too many open files ... I'm using Version 2.731 - linux-unix-gnu-x86.
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.
You should know the release of Chicken 4 is imminent. At which point Chicken 3 will go into maintenance mode.
Is this a bug, or is there some way for me to release these ports when I handle the exception?Thanks! Matt _______________________________________________ Chicken-users mailing list address@hidden http://lists.nongnu.org/mailman/listinfo/chicken-users
Best Wishes, Kon
[Prev in Thread] | Current Thread | [Next in Thread] |