Re: Blocking on a non-blocking socket?

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

 





On 24/05/2024 02:30, Wiebe Cazemier wrote:

Can you show me in the code where that is?

It's here:

https://github.com/openssl/openssl/blob/b9e084f139c53ce133e66aba2f523c680141c0e6/ssl/record/rec_layer_s3.c#L1038-L1054

The "retry" codepath occurs where we hit the "goto start".

My main concern is, if it would get an EWOULDBLOCK, there is (almost) no sense in retrying because in the 100 microseconds or so that passed, there is likely still no data.

This situation does not occur. The "auto-retry" only occurs in the case where we have *successfully* read a non-application data record. If we get an EWOULDBLOCK then this is always propagated back to the application.


> Wouldn't the option then have to be called 'read more than one record at a time'? To me, 'retry' is a bit of a misnomer in that description.

The "retry" here is the normal meaning of the English word, and does not refer to a "network" retry, i.e. we tried to read application data but actually got something else, so retry that attempt.

Matt






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

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux