#[export_name = "deflateReset"]
pub unsafe extern "C-unwind" fn deflateReset(
strm: *mut z_stream,
) -> i32
Expand description
This function is equivalent to deflateEnd
followed by deflateInit_
, but does not free and reallocate the internal compression state.
This function will leave the compression level and any other attributes that may have been set unchanged.
The stream’s total_in
, total_out
, adler
, and msg
fields are initialized.
§Returns
Z_OK
if successZ_STREAM_ERROR
if the stream state was inconsistent
§Safety
The caller must guarantee that
- Either
strm
isNULL
strm
satisfies the requirements of&mut *strm
and was initialized withdeflateInit_
or similar