There's still something I don't quite get yet:
If my app is a server and it waits for clients to connect, then the first
operation of the socket will be a read by the server. So if my server app
makes a select call on the socket, and I/O is detected on the socket, does
it matter whether or not the data is for the SSL layer or the application
layer? Does PR_Read handle that? Why would PR_Read block if there's I/O
waiting to be read???

-- POC

"John Gardiner Myers" <[EMAIL PROTECTED]> wrote in message
ajgb8r$98j$[EMAIL PROTECTED]">news:ajgb8r$98j$[EMAIL PROTECTED]...
>
>
> POC wrote:
> > Are you saying there needs to be more to the above logic in order to
> > use NSPR calls after a select call?
>
> Yes.  Sometimes a PR_Recv() on a PRFileDesc results in a write() on the
> underlying socket.  Sometimes when that write() returns EWOULDBLOCK, the
> only way the connection will make further progress would be for the
> application to wait until the underlying socket becomes writeable and
> then call PR_Recv() (or, as it happens, PR_Send()).
>



Reply via email to