[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[MiNT] tcp_select ( was: Re: inet4: errno is not set correct )
Am Sonntag, den 03.10.2010, 14:42 +0200 schrieb m0n0
<ole@monochrom.net>:
> Anyone is able to fix this, or maybe someone knows 
> more about the network code and can acknowledge this 
> bug at source level? 
I think this could be fixed in tcp_select... 
here is part of tcp_select function:
			switch (tcb->state)
			{
				case TCBS_SYNSENT:
				case TCBS_ESTABLISHED:
					break;
				default:
					return 1;
			}
			
			return so_rselect (so, proc);
Intentionally I would try to return 0 when tcb->state == TCBS_SYNSENT, 
at this time I just don't have the knowledge to build my own kernel ;) (
But I think I will dig into it because of this one..) 
Another problem I would have with that change: Is tcp_select only used
by user space applications? If it is also used by the kernel during TCP
handshake, then the TCBS_SYNSENT state of course must return 1... but I
guess it's not meant to be used within the kernel... 
On the other hand, I believe return 0 when tcb->state == TCBS_SYNSENT
won't be enough... TCBS_SYNRCVD is still handled by default and will
return 1, which seems to be wrong from my point of view. 
Anybody wants to talk about this =) ?
Greets,
m