summaryrefslogtreecommitdiffstats
path: root/thirdparty/zstd/common/fse.h
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2024-04-08 15:03:25 +0200
committerRémi Verschelde <rverschelde@gmail.com>2024-04-08 15:03:25 +0200
commit4d2e8e4cab5824d973f4a70bc271c461007c75fc (patch)
tree0a6ef767404661261264ebd55dc346dfeca625fb /thirdparty/zstd/common/fse.h
parent0e7c9d5338a108abde7b87a741482612f814155a (diff)
parenta88b4a4d56a923ad1f3652eb1133676f8c96c44d (diff)
downloadredot-engine-4d2e8e4cab5824d973f4a70bc271c461007c75fc.tar.gz
Merge pull request #90253 from akien-mga/zstd-1.5.6
zstd: Update to upstream version 1.5.6
Diffstat (limited to 'thirdparty/zstd/common/fse.h')
-rw-r--r--thirdparty/zstd/common/fse.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/thirdparty/zstd/common/fse.h b/thirdparty/zstd/common/fse.h
index 02a1f0bc53..2ae128e60d 100644
--- a/thirdparty/zstd/common/fse.h
+++ b/thirdparty/zstd/common/fse.h
@@ -229,6 +229,7 @@ If there is an error, the function will return an error code, which can be teste
#endif /* FSE_H */
+
#if defined(FSE_STATIC_LINKING_ONLY) && !defined(FSE_H_FSE_STATIC_LINKING_ONLY)
#define FSE_H_FSE_STATIC_LINKING_ONLY
@@ -464,13 +465,13 @@ MEM_STATIC void FSE_encodeSymbol(BIT_CStream_t* bitC, FSE_CState_t* statePtr, un
FSE_symbolCompressionTransform const symbolTT = ((const FSE_symbolCompressionTransform*)(statePtr->symbolTT))[symbol];
const U16* const stateTable = (const U16*)(statePtr->stateTable);
U32 const nbBitsOut = (U32)((statePtr->value + symbolTT.deltaNbBits) >> 16);
- BIT_addBits(bitC, statePtr->value, nbBitsOut);
+ BIT_addBits(bitC, (size_t)statePtr->value, nbBitsOut);
statePtr->value = stateTable[ (statePtr->value >> nbBitsOut) + symbolTT.deltaFindState];
}
MEM_STATIC void FSE_flushCState(BIT_CStream_t* bitC, const FSE_CState_t* statePtr)
{
- BIT_addBits(bitC, statePtr->value, statePtr->stateLog);
+ BIT_addBits(bitC, (size_t)statePtr->value, statePtr->stateLog);
BIT_flushBits(bitC);
}