fix(compress): gate MT frame callback by build feature
The MT frame-progression callback is only referenced when ZSTD_MULTITHREAD is enabled. Keep its definition under the same configuration guard so single-threaded library, test, and decode-corpus builds do not report an unused static function while the MT callback remains available to the Rust dispatch bridge. Test Plan: - git diff --cached --check - Capped full tests passed before this warning-only guard - Capped native rebuild and smoke rerun pending
This commit is contained in:
@@ -4439,15 +4439,12 @@ size_t ZSTD_estimateCStreamSize(int compressionLevel)
|
|||||||
* tells how much data has been consumed (input) and produced (output) for current frame.
|
* tells how much data has been consumed (input) and produced (output) for current frame.
|
||||||
* able to count progression inside worker threads (non-blocking mode).
|
* able to count progression inside worker threads (non-blocking mode).
|
||||||
*/
|
*/
|
||||||
static ZSTD_frameProgression ZSTD_rust_frameProgression_MT(void* context)
|
|
||||||
{
|
|
||||||
#ifdef ZSTD_MULTITHREAD
|
#ifdef ZSTD_MULTITHREAD
|
||||||
|
# static ZSTD_frameProgression ZSTD_rust_frameProgression_MT(void* context)
|
||||||
|
{
|
||||||
return ZSTDMT_getFrameProgression((ZSTDMT_CCtx*)context);
|
return ZSTDMT_getFrameProgression((ZSTDMT_CCtx*)context);
|
||||||
#else
|
|
||||||
(void)context;
|
|
||||||
return (ZSTD_frameProgression){ 0 };
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
ZSTD_frameProgression ZSTD_getFrameProgression(const ZSTD_CCtx* cctx)
|
ZSTD_frameProgression ZSTD_getFrameProgression(const ZSTD_CCtx* cctx)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user