git: 317c242462bb - stable/15 - tarfs: swap deprecated ZSTD_resetDStream() with ZSTD_DCtx_reset()
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 18 Mar 2026 14:21:33 UTC
The branch stable/15 has been updated by siva:
URL: https://cgit.FreeBSD.org/src/commit/?id=317c242462bb3c34452bf61eb7d99b741eb766a6
commit 317c242462bb3c34452bf61eb7d99b741eb766a6
Author: Siva Mahadevan <siva@FreeBSD.org>
AuthorDate: 2026-03-14 03:54:46 +0000
Commit: Siva Mahadevan <siva@FreeBSD.org>
CommitDate: 2026-03-18 13:49:53 +0000
tarfs: swap deprecated ZSTD_resetDStream() with ZSTD_DCtx_reset()
ZSTD_resetDStream() is deprecated since 1.5.4: https://github.com/facebook/zstd/commit/5d8cfa6b96a6442ab1251f9de3b47a0eb12561a0
This change is needed to MFV zstd 1.5.7.
Approved by: emaste (mentor)
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D55835
(cherry picked from commit 922d73540d2d9897e5e8160c445cefa13581564e)
---
sys/fs/tarfs/tarfs_io.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/sys/fs/tarfs/tarfs_io.c b/sys/fs/tarfs/tarfs_io.c
index e250c5cbce5a..0eff12c21d3f 100644
--- a/sys/fs/tarfs/tarfs_io.c
+++ b/sys/fs/tarfs/tarfs_io.c
@@ -355,7 +355,7 @@ tarfs_zread_zstd(struct tarfs_zio *zio, struct uio *uiop)
if (reset) {
zio->ipos = zio->idx[zio->curidx].i;
zio->opos = zio->idx[zio->curidx].o;
- ZSTD_resetDStream(zstd->zds);
+ ZSTD_DCtx_reset(zstd->zds, ZSTD_reset_session_only);
TARFS_DPF(ZIDX, "%s: skipping to index %u = i %zu o %zu\n", __func__,
zio->curidx, (size_t)zio->ipos, (size_t)zio->opos);
} else {
@@ -511,7 +511,7 @@ fail_unlocked:
zio->curidx = 0;
zio->ipos = zio->idx[0].i;
zio->opos = zio->idx[0].o;
- ZSTD_resetDStream(zstd->zds);
+ ZSTD_DCtx_reset(zstd->zds, ZSTD_reset_session_only);
}
return (error);
}