Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions client/archive.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,11 @@ func Extract(ctx context.Context, r io.Reader, directory string, threads int) er
return errors.Join(errs...)
}

// runTarZstdPipeline runs tar piped through zstd, writing compressed output
// runTarZstdPipeline runs tar piped through pzstd, writing compressed output
// to w. The caller is responsible for closing w after this returns.
func runTarZstdPipeline(ctx context.Context, tarArgs []string, threads int, w io.Writer) error {
tarCmd := exec.CommandContext(ctx, "tar", tarArgs...)
zstdCmd := exec.CommandContext(ctx, "zstd", "-c", fmt.Sprintf("-T%d", threads)) //nolint:gosec
zstdCmd := exec.CommandContext(ctx, "pzstd", "-c", fmt.Sprintf("-p%d", threads)) //nolint:gosec

// Manual pipe so we can close both ends in the parent after starting
// children. Prevents deadlock if zstd exits while tar is still writing:
Expand Down
Loading