< prev index next >

src/java.base/share/classes/java/io/PushbackInputStream.java

Print this page

        

*** 87,96 **** --- 87,99 ---- * @exception IllegalArgumentException if {@code size <= 0} * @since 1.1 */ public PushbackInputStream(InputStream in, int size) { super(in); + if (in == null) { + throw new NullPointerException(); + } if (size <= 0) { throw new IllegalArgumentException("size <= 0"); } this.buf = new byte[size]; this.pos = size;
< prev index next >