Check noJdkZlibEncoder before comparing other parameters
.. for consistency
This commit is contained in:
parent
8cb6b779c9
commit
2026f15be2
@ -90,9 +90,8 @@ public final class ZlibCodecFactory {
|
||||
}
|
||||
|
||||
public static ZlibEncoder newZlibEncoder(int compressionLevel, int windowBits, int memLevel, byte[] dictionary) {
|
||||
if (PlatformDependent.javaVersion() < 7 ||
|
||||
windowBits != DEFAULT_JDK_WINDOW_SIZE || memLevel != DEFAULT_JDK_MEM_LEVEL ||
|
||||
noJdkZlibEncoder) {
|
||||
if (PlatformDependent.javaVersion() < 7 || noJdkZlibEncoder ||
|
||||
windowBits != DEFAULT_JDK_WINDOW_SIZE || memLevel != DEFAULT_JDK_MEM_LEVEL) {
|
||||
return new JZlibEncoder(compressionLevel, windowBits, memLevel, dictionary);
|
||||
} else {
|
||||
return new JdkZlibEncoder(compressionLevel, dictionary);
|
||||
|
Loading…
Reference in New Issue
Block a user