From a4645d3aa4e647b442aee5c7f0ab50f501ba9790 Mon Sep 17 00:00:00 2001 From: Wilfried Goesgens Date: Thu, 4 Nov 2010 20:28:27 +0100 Subject: [PATCH] fix crash in SSL BLOB-Reading - when diciding whether the read buffer contains more than the blob reader wants we had a wrong equation. --- citadel/modules/crypto/serv_crypto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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, -- 2.30.2