Am 21.06.2022 um 12:37 schrieb massimiliano cialdi via lwip-users:
hello,

the setsockopt(SO_RCVTIMEO) POSIX call contemplates the possibility of
imposing 0 as the 'timeout' parameter, and in that case that socket
becomes non-blocking (See, for example,
https://stackoverflow.com/questions/49706883/disable-socket-timeout-via-setsockopt).


Sorry, but stackoverflow is *not* a good source to cite when talking
about POSIX standard.

Instead, I prefer to search opengroup.com and on the 'setsockopt' page
google gives me
(https://pubs.opengroup.org/onlinepubs/000095399/functions/setsockopt.html),
I find this in the description of SO_RCVTIMEO:

"The default for this option is zero, which indicates that a receive
operation shall not time out."

BTW, even the stackoverflow page you cited says: "If the timeout is set
to zero (the default) then the operation will never timeout".

Regards,
Simon

_______________________________________________
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to