throwZstdError

private fnvoid throwZstdError(size_t rc, string context)

Throw a CompressionError classified from a ZSTD return code.

Parameters

rcThe return value from a libzstd function (must be an error).
contextA context string identifying the operation that failed.

Throws

CompressionError with an ErrorCode mapped from the libzstd error

and the original zstd error name in the message.