[Top][All Lists]

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

Re: [Help-smalltalk] Re: Exception in the socket code

From: Paolo Bonzini
Subject: Re: [Help-smalltalk] Re: Exception in the socket code
Date: Fri, 25 Mar 2011 21:56:38 +0100
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.7

On 03/25/2011 09:54 PM, Holger Hans Peter Freyther wrote:
On 03/25/2011 03:33 PM, Paolo Bonzini wrote:

Now that I think of it, while my patch to the buffer classes is good for GST,
you may want to replace the two implementations of #close with just "self halt".

turns out that sockets use a different set of prims to read/write and that the
primitive does not set the errno like the 'normal' one does. My test case
right now is to connect a remote IP... and after this patch I do get a
connection refused File error.

diff --git a/libgst/prims.def b/libgst/prims.def
index db3254d..efd83b2 100644
--- a/libgst/prims.def
+++ b/libgst/prims.def
@@ -5861,6 +5861,8 @@ primitive VMpr_FileDescriptor_socketOp [succeed,fail]

+  if (errno)
+    _gst_set_errno (errno);

Right, because I thought I'd use SO_ERROR.  Good catch, thanks!


reply via email to

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