8231490: Ugly racy writes to ZipUtils.defaultBuf

Reviewed-by: lancea
This commit is contained in:
Eamonn McManus 2021-11-08 19:57:44 +00:00
parent e383d26361
commit 905e3e8813

View File

@ -419,7 +419,9 @@ public class Inflater {
needDict = true; needDict = true;
} }
if (input != null) { if (input != null) {
if (read > 0) {
input.position(inputPos + read); input.position(inputPos + read);
}
} else { } else {
this.inputPos = inputPos + read; this.inputPos = inputPos + read;
} }