summaryrefslogtreecommitdiffstats
path: root/crypto/comp
diff options
context:
space:
mode:
authorBodo Möller <bodo@openssl.org>2011-02-03 12:03:57 +0000
committerBodo Möller <bodo@openssl.org>2011-02-03 12:03:57 +0000
commita288aaefc4c3189ec4fe80456e98d242e1be9173 (patch)
treedead31ffc77ff282edd7dabc5904b70fbf4a9d5e /crypto/comp
parenteed56c77b46c5bc134bdae335cf2c73a31bfd1a0 (diff)
Assorted bugfixes:
- safestack macro changes for C++ were incomplete - RLE decompression boundary case - SSL 2.0 key arg length check Submitted by: Google (Adam Langley, Neel Mehta, Bodo Moeller)
Diffstat (limited to 'crypto/comp')
-rw-r--r--crypto/comp/c_rle.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/crypto/comp/c_rle.c b/crypto/comp/c_rle.c
index efd366fa22..47dfb67fbd 100644
--- a/crypto/comp/c_rle.c
+++ b/crypto/comp/c_rle.c
@@ -30,7 +30,7 @@ static int rle_compress_block(COMP_CTX *ctx, unsigned char *out,
{
/* int i; */
- if (olen < (ilen+1))
+ if (ilen == 0 || olen < (ilen-1))
{
/* ZZZZZZZZZZZZZZZZZZZZZZ */
return(-1);
@@ -59,4 +59,3 @@ static int rle_expand_block(COMP_CTX *ctx, unsigned char *out,
}
return(ilen-1);
}
-