From 5cccd77c5567547f0ad401c6b12424cd6634c310 Mon Sep 17 00:00:00 2001 From: inikep Date: Wed, 2 Mar 2016 20:37:49 +0100 Subject: [PATCH] fix clang -Wcast-align warning (part 2) --- lib/zstd_compress.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/zstd_compress.c b/lib/zstd_compress.c index 6a4cfe4c..50fa2fdc 100644 --- a/lib/zstd_compress.c +++ b/lib/zstd_compress.c @@ -207,8 +207,8 @@ static size_t ZSTD_resetCCtx_advanced (ZSTD_CCtx* zc, zc->seqStore.litLengthStart = zc->seqStore.litStart + blockSize; zc->seqStore.matchLengthStart = zc->seqStore.litLengthStart + (blockSize>>2); zc->seqStore.dumpsStart = zc->seqStore.matchLengthStart + (blockSize>>2); - BYTE* dumpsEnd = zc->seqStore.dumpsStart + (blockSize>>2); - zc->seqStore.litFreq = (U32*)(dumpsEnd); + + zc->seqStore.litFreq = (U32*)((void*)(zc->seqStore.dumpsStart + (blockSize>>2))); zc->seqStore.litLengthFreq = zc->seqStore.litFreq + (1<seqStore.matchLengthFreq = zc->seqStore.litLengthFreq + (1<seqStore.offCodeFreq = zc->seqStore.matchLengthFreq + (1<