RFR: 8263560: Remove needless wrapping with BufferedInputStream [v4]
Сергей Цыпанов
github.com+10835776+stsypanov at openjdk.java.net
Mon Mar 15 08:36:28 UTC 2021
> In some cases wrapping of `InputStream` with `BufferedInputStream` is redundant, e.g. in case the wrapped one is `ByteArrayOutputStream` which does not require any buffer having one within.
>
> Other cases are related to reading either a byte or short `byte[]`: in both cases `BufferedInputStream.fill()` will be called resulting in load of much bigger amount of data (8192 by default) than required.
Сергей Цыпанов has updated the pull request incrementally with one additional commit since the last revision:
Fix formatting
-------------
Changes:
- all: https://git.openjdk.java.net/jdk/pull/2992/files
- new: https://git.openjdk.java.net/jdk/pull/2992/files/a016d2ac..f69c8ff4
Webrevs:
- full: https://webrevs.openjdk.java.net/?repo=jdk&pr=2992&range=03
- incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=2992&range=02-03
Stats: 2 lines in 1 file changed: 1 ins; 0 del; 1 mod
Patch: https://git.openjdk.java.net/jdk/pull/2992.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/2992/head:pull/2992
PR: https://git.openjdk.java.net/jdk/pull/2992
More information about the net-dev
mailing list