luben / zstd-jni

JNI binding for Zstd
Other
808 stars 165 forks source link

Limit the maximal block size while decompress #302

Closed normanmaurer closed 3 months ago

normanmaurer commented 3 months ago

Is there a way how I can limit the maximum block size that I want to "accept" in the decompression side ? Like I would like to throw an exception if the block is too big.

luben commented 3 months ago

There is already upper limit of 128KB for the block size, see Is there a way how I can limit the maximum block size that I want to "accept" in the decompression side ? Like I would like to throw an exception if the block is too big.

normanmaurer commented 3 months ago

@luben ah perfect!