Correctly check return value of SSL_write.

This commit is contained in:
Jonathan Schleifer 2011-09-11 04:07:08 +02:00
parent 0185f9bc7b
commit 59a56bca2a

View file

@ -245,7 +245,7 @@ static SSL_CTX *ctx;
@throw e;
}
if (SSL_write(ssl, buffer, (int)length) < 1)
if (SSL_write(ssl, buffer, (int)length) < length)
@throw [OFWriteFailedException newWithClass: isa
stream: self
requestedLength: length];