...
This noncompliant code example creates multiple BufferedInputStreams
on System.in
. Although it will work when System.in
refers to a console, it crashes when System.in
has been redirected to a file. Note that while this code uses a BufferedInputStream
to illustrate that any buffered wrapper is unsafe, it is also exploitable if a Scanner
is used instead.
...