@jmehrens what about this then? I think it safe now(actually this mechanism is learned from Reader)
------------- Commit messages: - store skip buffers in InputStream Object Changes: https://git.openjdk.java.net/jdk/pull/5872/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=5872&range=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8284638 Stats: 9 lines in 1 file changed: 8 ins; 0 del; 1 mod Patch: https://git.openjdk.java.net/jdk/pull/5872.diff Fetch: git fetch https://git.openjdk.java.net/jdk pull/5872/head:pull/5872 PR: https://git.openjdk.java.net/jdk/pull/5872