On Sun, Jun 20, 2010 at 17:22, Holger Hans Peter Freyther
<[email protected]> wrote:
>> Why?  You just won't get any datagram, AFAIU.
>
> Sure, you will not get any datagram and the read should fail pretty fast.
>
> st> Sockets.DatagramSocket local: '8.8.8.8' port: 23000
> Sockets.DatagramSocket[0.0.0.0:0]
>
> generates the following syscalls:
>
> bind(3, {sa_family=AF_INET, sin_port=htons(23000),
> sin_addr=inet_addr("8.8.8.8")}, 16) = -1 EADDRNOTAVAIL (Cannot assign
> requested address)
> getsockopt(3, SOL_SOCKET, SO_ERROR, [0], [4]) = 0
> getsockname(3, {sa_family=AF_INET, sin_port=htons(0),
> sin_addr=inet_addr("0.0.0.0")}, [16]) = 0
>
> and I think the failure of the bind should be propagated as an
> exception, it does not as the SOL_ERROR is not reporting any error (okay
> I didn't verify that).

Yes, that's correct.  Maybe it's a kernel bug.

Paolo

_______________________________________________
help-smalltalk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-smalltalk

Reply via email to