Skip to content

Commit e4378ab

Browse files
committedMay 14, 2022
8286559: Re-examine synchronization of mark and reset methods on InflaterInputStream
Reviewed-by: lancea, alanb, bpb
1 parent f56396f commit e4378ab

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed
 

‎src/java.base/share/classes/java/util/zip/InflaterInputStream.java

+6-4
Original file line numberDiff line numberDiff line change
@@ -264,29 +264,31 @@ public boolean markSupported() {
264264
/**
265265
* Marks the current position in this input stream.
266266
*
267-
* <p> The {@code mark} method of {@code InflaterInputStream}
267+
* @implSpec The {@code mark} method of {@code InflaterInputStream}
268268
* does nothing.
269269
*
270270
* @param readlimit the maximum limit of bytes that can be read before
271271
* the mark position becomes invalid.
272272
* @see java.io.InputStream#reset()
273273
*/
274-
public synchronized void mark(int readlimit) {
274+
@Override
275+
public void mark(int readlimit) {
275276
}
276277

277278
/**
278279
* Repositions this stream to the position at the time the
279280
* {@code mark} method was last called on this input stream.
280281
*
281-
* <p> The method {@code reset} for class
282+
* @implSpec The method {@code reset} for class
282283
* {@code InflaterInputStream} does nothing except throw an
283284
* {@code IOException}.
284285
*
285286
* @throws IOException if this method is invoked.
286287
* @see java.io.InputStream#mark(int)
287288
* @see java.io.IOException
288289
*/
289-
public synchronized void reset() throws IOException {
290+
@Override
291+
public void reset() throws IOException {
290292
throw new IOException("mark/reset not supported");
291293
}
292294
}

1 commit comments

Comments
 (1)

openjdk-notifier[bot] commented on May 14, 2022

@openjdk-notifier[bot]
Please sign in to comment.