8286559: Re-examine synchronization of mark and reset methods on InflaterInputStream
Reviewed-by: lancea, alanb, bpb
This commit is contained in:
parent
f56396f168
commit
e4378ab28d
@ -264,21 +264,22 @@ public class InflaterInputStream extends FilterInputStream {
|
||||
/**
|
||||
* Marks the current position in this input stream.
|
||||
*
|
||||
* <p> The {@code mark} method of {@code InflaterInputStream}
|
||||
* @implSpec The {@code mark} method of {@code InflaterInputStream}
|
||||
* does nothing.
|
||||
*
|
||||
* @param readlimit the maximum limit of bytes that can be read before
|
||||
* the mark position becomes invalid.
|
||||
* @see java.io.InputStream#reset()
|
||||
*/
|
||||
public synchronized void mark(int readlimit) {
|
||||
@Override
|
||||
public void mark(int readlimit) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Repositions this stream to the position at the time the
|
||||
* {@code mark} method was last called on this input stream.
|
||||
*
|
||||
* <p> The method {@code reset} for class
|
||||
* @implSpec The method {@code reset} for class
|
||||
* {@code InflaterInputStream} does nothing except throw an
|
||||
* {@code IOException}.
|
||||
*
|
||||
@ -286,7 +287,8 @@ public class InflaterInputStream extends FilterInputStream {
|
||||
* @see java.io.InputStream#mark(int)
|
||||
* @see java.io.IOException
|
||||
*/
|
||||
public synchronized void reset() throws IOException {
|
||||
@Override
|
||||
public void reset() throws IOException {
|
||||
throw new IOException("mark/reset not supported");
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user