aboutsummaryrefslogtreecommitdiff
path: root/src/liblzma
diff options
context:
space:
mode:
authorLasse Collin <lasse.collin@tukaani.org>2007-12-09 11:24:48 +0200
committerLasse Collin <lasse.collin@tukaani.org>2007-12-09 11:24:48 +0200
commitff946ceb7975d4f11950afd33f6315b4d20d1a03 (patch)
tree6240c77a7cb09f0fb95c54118f22121a403e800d /src/liblzma
parentFixed the tests to build with -Werror. (diff)
downloadxz-ff946ceb7975d4f11950afd33f6315b4d20d1a03.tar.xz
Re-enabled the security checks in Subblock decoder
that were disabled for debugging reasons.
Diffstat (limited to 'src/liblzma')
-rw-r--r--src/liblzma/subblock/subblock_decoder.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/liblzma/subblock/subblock_decoder.c b/src/liblzma/subblock/subblock_decoder.c
index ef3c289f..e0a46f45 100644
--- a/src/liblzma/subblock/subblock_decoder.c
+++ b/src/liblzma/subblock/subblock_decoder.c
@@ -177,9 +177,9 @@ decode_buffer(lzma_coder *coder, lzma_allocator *allocator,
switch (in[*in_pos] >> 4) {
case FLAG_PADDING:
// Only check that reserved bits are zero.
-// if (++coder->padding > PADDING_MAX
-// || in[*in_pos] & 0x0F)
-// return LZMA_DATA_ERROR;
+ if (++coder->padding > PADDING_MAX
+ || in[*in_pos] & 0x0F)
+ return LZMA_DATA_ERROR;
++*in_pos;
break;