On Saturday 31 March 2007 00:26, David Schwartz wrote:
I see, so if I disable PARTIAL_WRITES, will that mean that it will return
values as I wrote up there?
PARTIAL_WRITES has no effect on the meaning of the return value. It just
controls whether or not the internal write logic tries to
It's just this I'm having a hard trouble to grasp.
Normally with say 'write' I would do
// pseudo code
while(written len)
written += write(fd, my_packet + written, len - written);
But because SSL_write handles an internal queue and calls for
sending the same
argument all the time I
So what would be your recommendation?
Partial writes or not ?
Sane non-blocking implementations pretty much have to enable 'partial
writes' and 'enable moving write buffer'. Otherwise the semantics become
insane, as you pointed out.
It all seems a bit unclear to me still I'm afraid. mostly
Hi,
I've been trying to figure out (plus testing) how to actually
use SSL_write.
Call SSL_write with the same parameters until it succeeds. You need
to handle WANT_READ and WANT_WRITE return values.
Mark
__
OpenSSL Project
Hi,
I've been trying to figure out (plus testing) how to actually
use SSL_write.
Call SSL_write with the same parameters until it succeeds. You need
to handle WANT_READ and WANT_WRITE return values.
I guess that is clear enough.
but does that imply if I call
SSL_write(ssl, buffer, len),
Call SSL_write with the same parameters until it succeeds. You need
to handle WANT_READ and WANT_WRITE return values.
I guess that is clear enough.
but does that imply if I call
SSL_write(ssl, buffer, len),
it will ONLY return len
or 0 ?
I mean if it returns len/2 (sent only half
On Friday 30 March 2007 22:41, David Schwartz wrote:
Call SSL_write with the same parameters until it succeeds. You need
to handle WANT_READ and WANT_WRITE return values.
I guess that is clear enough.
but does that imply if I call
SSL_write(ssl, buffer, len),
it will ONLY return
I see, so if I disable PARTIAL_WRITES, will that mean that it will return
values as I wrote up there?
PARTIAL_WRITES has no effect on the meaning of the return value. It just
controls whether or not the internal write logic tries to continue writing
if the underlying write partially completes.
Hi,
I've been trying to figure out (plus testing) how to actually use SSL_write.
I write alot of data and have an internal Send Queue in which I keep
packets.
I try to follow this reasoning:
1) try to write the entire chunk with SSL_write
if it returns the same value as 'len' then it