Skip to content

adb_comp: fix writing and parsing of compspec, better zstd default

nina requested to merge q66/apk-tools:comp-fixes into master

The compression spec parsing was broken as it was assuming that strchr would return a pointer to a null terminator, which it does not. The additional colon check was also useless (inside that if, colon can be the only character at that address).

The compression spec writing was broken as it was writing a pointer address and not the actual spec.

Also, use a better default for zstd. The actual default for 0 is 3, which is generally not what one may want. Use 9 for a good speed/size tradeoff.

Merge request reports

Loading