aboutsummaryrefslogtreecommitdiff
path: root/archival/libunarchive/unxz/xz_dec_bcj.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2010-06-01 14:41:39 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2010-06-01 14:41:39 +0200
commit716f3f612e62c55edd052b505a86e4e2e09074a5 (patch)
treeb930509d157cdf4fb3d80fb2633d3da500eb8e90 /archival/libunarchive/unxz/xz_dec_bcj.c
parent11bcf4b22449d08b61617183c1951db98457653a (diff)
downloadbusybox-716f3f612e62c55edd052b505a86e4e2e09074a5.tar.gz
decompress_unxz: newer version, one which can unpack SHA-256 protected files
function old new delta check_sizes - 16 +16 crc32_table - 4 +4 index_update 47 40 -7 crc32_validate 110 93 -17 dec_vli 197 165 -32 unpack_xz_stream 4284 4014 -270 ------------------------------------------------------------------------------ (add/remove: 2/0 grow/shrink: 0/4 up/down: 20/-326) Total: -306 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'archival/libunarchive/unxz/xz_dec_bcj.c')
-rw-r--r--archival/libunarchive/unxz/xz_dec_bcj.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/archival/libunarchive/unxz/xz_dec_bcj.c b/archival/libunarchive/unxz/xz_dec_bcj.c
index d4b6ef751..09162b51f 100644
--- a/archival/libunarchive/unxz/xz_dec_bcj.c
+++ b/archival/libunarchive/unxz/xz_dec_bcj.c
@@ -10,6 +10,12 @@
#include "xz_private.h"
+/*
+ * The rest of the file is inside this ifdef. It makes things a little more
+ * convenient when building without support for any BCJ filters.
+ */
+#ifdef XZ_DEC_BCJ
+
struct xz_dec_bcj {
/* Type of the BCJ filter being used */
enum {
@@ -331,7 +337,6 @@ static noinline_for_stack size_t XZ_FUNC bcj_sparc(
}
#endif
-#ifdef XZ_DEC_BCJ
/*
* Apply the selected BCJ filter. Update *pos and s->pos to match the amount
* of data that got filtered.
@@ -388,9 +393,7 @@ static void XZ_FUNC bcj_apply(struct xz_dec_bcj *s,
*pos += filtered;
s->pos += filtered;
}
-#endif
-#ifdef XZ_DEC_BCJ
/*
* Flush pending filtered data from temp to the output buffer.
* Move the remaining mixture of possibly filtered and unfiltered
@@ -557,4 +560,5 @@ XZ_EXTERN enum xz_ret XZ_FUNC xz_dec_bcj_reset(
return XZ_OK;
}
+
#endif