mirror of
https://github.com/facebook/zstd.git
synced 2025-10-08 00:04:02 -04:00
fullbench 43: ensure context is freed after each usage
This commit is contained in:
parent
eb6b199038
commit
c63081623f
@ -166,11 +166,14 @@ local_ZSTD_compressStream_freshCCtx(const void* src, size_t srcSize,
|
||||
void* buff2)
|
||||
{
|
||||
ZSTD_CCtx* const cctx = ZSTD_createCCtx();
|
||||
size_t r;
|
||||
assert(cctx != NULL);
|
||||
|
||||
return local_ZSTD_compressStream(src, srcSize, dst, dstCapacity, buff2);
|
||||
r = local_ZSTD_compressStream(src, srcSize, dst, dstCapacity, buff2);
|
||||
|
||||
ZSTD_freeCCtx(cctx);
|
||||
|
||||
return r;
|
||||
}
|
||||
|
||||
static size_t
|
||||
|
Loading…
x
Reference in New Issue
Block a user