summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
383efb2)
*/
@Override
public synchronized int available() throws IOException {
*/
@Override
public synchronized int available() throws IOException {
+ if (remaining == 0) {
+ return 0;
+ }
return (int) Math.min(super.available(), Math.min(Integer.MAX_VALUE, remaining));
}
return (int) Math.min(super.available(), Math.min(Integer.MAX_VALUE, remaining));
}
*/
@Override
public synchronized long skip(long n) throws IOException {
*/
@Override
public synchronized long skip(long n) throws IOException {
+ if ((n < 0) || (remaining == 0)) {
return 0;
}
long skipped = super.skip(Math.min(n, remaining));
return 0;
}
long skipped = super.skip(Math.min(n, remaining));