On Tue, Apr 13, 1999 at 06:49:37PM +0200, Richard Levitte - VMS Whacker wrote:

[...]
> What can be regarded as odd is that SSL_read() can return 0 even if it
> hasn't reached EOF.  read() does this in non-blocking mode, but if I
> understood everything correctly, SSL does blocking I/O exclusively.

SSLeay/OpenSSL can cope with non-blocking I/O.  It keeps enough
internal state so that a new call to SSL_read or SSL_write will do
whatever remains to be done, if the application uses the library in
the intended way.  Unfortunately, the lack of documentation can make
things rather difficult for the programmer because often you don't
really know what you're supposed to do (I recently claimed that the
apps/ directory serves as documentation, but at that moment s_client.c
still had a bug w.r.t. its I/O behaviour [even for blocking I/O], so
it wasn't a particularly good piece of documentation -- anyway, you
might want to examine s_client.c and look at its "-nbio" option to see
that non-blocking I/O indeed works.)
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to