From: Wilfried Goesgens Date: Thu, 4 Nov 2010 19:28:27 +0000 (+0100) Subject: fix crash in SSL BLOB-Reading X-Git-Tag: v8.01~611 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=a4645d3aa4e647b442aee5c7f0ab50f501ba9790 fix crash in SSL BLOB-Reading - when diciding whether the read buffer contains more than the blob reader wants we had a wrong equation. --- diff --git a/citadel/modules/crypto/serv_crypto.c b/citadel/modules/crypto/serv_crypto.c index e962d7f01..e10cb79f0 100644 --- a/citadel/modules/crypto/serv_crypto.c +++ b/citadel/modules/crypto/serv_crypto.c @@ -603,7 +603,7 @@ int client_read_sslblob(StrBuf *Target, long bytes, int timeout) retval = client_read_sslbuffer(CCC->ReadBuf, timeout); if (retval >= 0) { RemainRead = bytes - (StrLength (Target) - baselen); - if (RemainRead > StrLength(CCC->ReadBuf)) + if (RemainRead < StrLength(CCC->ReadBuf)) { StrBufAppendBufPlain( Target,