[iolib-devel] compilation error
Peter Keller
psilord at cs.wisc.edu
Sat Dec 26 20:05:28 UTC 2009
On Thu, Dec 24, 2009 at 07:19:59PM -0600, Peter Keller wrote:
> So, after all that, now I have to check out to see if the echo-server.lisp
> program works. :)
Ok, after some experimentation and writing my own code based off of the
echo-server.lisp code, I've found a bug in the echo-server.lisp code:
In function make-listener-handler, it will timeout after a certain amount
of time, this clause is supposed to fire:
(when (eql :timeout event)
(warn "Got a server timeout!")
(return))
However, it won't because the (eql :timeout event) should be
(eql :timeout exception) instead.
The current behavior of the bug is after 15 seconds, the server becomes
completely unresponsive. By default this isn't seen because the timeout
for the server itself is 10 seconds.
Also, unrelated, the (defvar *sockets* (make-hash-table)) at the top of
the file should be (defvar *sockets* nil) instead.
Now, a question, is there a means by which I can have iomux:event-dispatch
return control to me for a while at specified intervals, and then go
back to multiplexing i/o? This would allow me to not have to put the
server machinery into the read/write functions on the streams themselves
or be beholden to my processing only on communication boundaries. If I
can get a single threaded solution, then I wouldn't have to worry about
the usual things with threads concerning data races and whatnot.
I'm looking forward to a new release of iolib, especially to get an
updated API description on the online manual.
Thank you.
-pete
More information about the iolib-devel
mailing list