[En-Nut-Discussion] Socket timeout
Alexander Baranov
Baranov at intech21.com
Sat Oct 12 17:50:19 CEST 2002
Hello, Harald,
Please, explain, does 'no timeout' mean infinite waiting or immediate
release? If I set timeout, will I eliminate possible infinite waiting loops
or - vice a versa - aggravate the situation. I'm sorry for such
persistence, but I cannot verify it for sure, because sometimes the
connection is good and sometimes it hangs without obvious reasons.
Regards, Alex
----- Original Message -----
From: "Harald Kipp" <harald.kipp at egnite.de>
To: <en-nut-discussion at egnite.de>
Sent: Saturday, October 12, 2002 9:07 AM
Subject: Re: [En-Nut-Discussion] Socket timeout
> Alexander,
>
> By default there's no timeout. You need to call
> NutTcpSetSockOpt() to set the timeout in
> milliseconds. Here's an example for 5 sec timeout:
>
> u_long to = 5000;
> if(NutTcpSetSockOpt(sock, SO_RCVTIMEO, &to, sizeof(to)))
> NutPrintString(0, "Sockopt TO failed\r\n");
>
> Harald
>
> _______________________________________________
> En-Nut-Discussion mailing list
> En-Nut-Discussion at egnite.de
> http://www.egnite.de/mailman/listinfo/en-nut-discussion
More information about the En-Nut-Discussion
mailing list