[slime-devel] Connection to Emacs lost. condition: junk in string

Kelly McDonald kelly at fammcdonald.net
Sat Jun 27 10:50:38 UTC 2009


Helmut,
Thanks for your reply.
I believe what is happening is that read-sequence is running out of
bytes to read from the socket, resulting in a top-level error, causing
it to go back to process-requests
which tries to decode-event on a socket that has a partially read
packet queued up.

I'm guessing that there is something that needs to be done to turn the
socket into a somewhat friendlier stream in swank-sbcl/socket-fd so
that you don't get the toplevel error when
read-sequence out-runs the socket. - but that is just a guess.

any pointers would be welcome!

Thanks,
Kelly

On Fri, Jun 26, 2009 at 11:39 AM, Helmut Eller<heller at common-lisp.net> wrote:
> * Kelly McDonald [2009-06-26 02:03+0200] writes:
>
>> 1) Threads were not available
>> 2) the read-packet was getting interrupted by another swank event, it
>> would read the packet length from the stream, but the first event had
>> not finished yet so it was reading random characters in the first
>> event to determine the length of the next packet and it crashed in
>> parse-integer
>> 3) wait-for-event was being recalled before the event had completely decoded.
>
> In theory, interrupts are queued during wait-for-event and processed at
> the next safe point.  If the queue grows to large (3) we invoke the
> debugger immediately.  In other words, the user needs to press C-c C-b
> three times in a row to get a partially decoded packet.  At least that's
> the theory.
>
> Helmut.
>
>
> _______________________________________________
> slime-devel site list
> slime-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/slime-devel
>




More information about the slime-devel mailing list