Hello,
>       For some reason I didn't get the original post, so I'm replying to the
> reply.
> 
> > In a blocking socket when a network read freezes, it
> > is normal. It only means that nothing arrived on the
> > socket.
> >
> > You got to take a look at the MSN protocol. With HTTP,
> > it might be sending a TCP FIN or something which is
> > why it is working in that case...
> 
>       Exactly.
> 
> > > after each request, I loop BIO_read until it returns
> > > a value <= 0.
> [snip]
> > > my case. I have
> > > to idea how to approach this problem. Do
> > > I have to use another way to see wether data is
> > > available to read
> > > from the BIO before calling BIO_read to
> > > prevent it from freezing? Any help would be
> > > appreciated.
> 
>       Follow the protocol. Only call 'BIO_read' if you know, based on the
> protocol you are using, that the other side is going to send more data (or
> close the connection).
> 
>       If the protocol is layered on top of HTTP, you can solve this just by
> specifying 'HTTP/1.0' and sending no 'Connection' header. This will require
> the server to close the connection after it sends its reply. This isn't
> efficient if you need to send more requests, but it does simplify things on
> your end.
To clarify: HTTP 1.0 do not have persistent connection so "connection"
has no meaning for HTTP 1.0 and server should drop connection after
servicing such client request. For HTTP 1.1 persistent connection is
default so if client wants that server should disconnect after
servicing request, client should add "Connection: close"
to http request. This may be done on any HTTP 1.1 request
within persistent connection.

Best regards,
-- 
Marek Marcola <[EMAIL PROTECTED]>

______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to