Hi > The error codes "WANT_READ" and "WANT_WRITE" help you determine which > of those 4 is most likely ready, but as soon as all 4 API entrypoints > say they can do no more until you provide them with more data/extract > some data from them, then you know that to be true. > > Someone please correct me if I got this wrong. > > Enjoy > > Jakob
So in each instance below, when I call ssl_read, I call it until I receive WANT_READ to ensure I've read everything. So what I'm seeing is this: - socket 1: ssl_read returns WANT_READ - socket 2: ssl_read returns some data, then WANT_READ. As this returned some data and made progress, I retry all operations again (I am correct to do this yes?); - socket 1: ssl_read returns WANT_READ - socket 2: ssl_read returns WANT_READ As all have returned WANT_READ, I wait on select. However I haven't received all the data that the client has sent yet and it waits on select. When I have my client start another connection (while keeping the first two active), this happens: - select returns - socket 1: ssl_read returns some data, then WANT_READ (even though the client hasn't sent anything on this socket) - socket 2: ssl_read WANT_READ - socket 3: (the newly connected socket) ssl_read returns some data, then WANT_READ. So the only way to get the data from socket 1 is for select to return on something else. What I think is happening is that the data for socket 1 has already arrived and been read into openssl (hence select waits). However I didn't get the data on the earlier call. ______________________________________________________________________ OpenSSL Project http://www.openssl.org User Support Mailing List openssl-users@openssl.org Automated List Manager majord...@openssl.org