miniz_oxide icon indicating copy to clipboard operation
miniz_oxide copied to clipboard

Is TINFL_FLAG_HAS_MORE_INPUT necessary?

Open Plecra opened this issue 5 years ago • 1 comments

https://github.com/Frommi/miniz_oxide/blob/7f5aedd7cc553b624902210a7d136440c138dc80/miniz_oxide/src/inflate/core.rs#L600-L607

It seems like the flag only serves to rename the NeedsMoreInput variant to FailedCannotMakeProgress at runtime. Both of the errors only seem to be created in this function. The API doesn't seem to do much but confuse users, so could it be removed? (NeedsMoreInput is a perfectly reasonable error state if the caller already knows there's no more input)

Plecra avatar Jul 09 '20 21:07 Plecra

Not sure, will have to look into it, some of these flags are remnants from porting miniz from C.

oyvindln avatar Aug 05 '20 13:08 oyvindln