summaryrefslogtreecommitdiffstats
path: root/libjava/java
diff options
context:
space:
mode:
authormkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4>2003-10-15 14:02:37 +0000
committermkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4>2003-10-15 14:02:37 +0000
commitfc2ed4c70573a5848c72e7b163671b5c164635ca (patch)
treea634bf2ea252b6868be619219a02042b257a6544 /libjava/java
parent93d5c37fef2b33305c13655394c767646d3c40df (diff)
downloadppe42-gcc-fc2ed4c70573a5848c72e7b163671b5c164635ca.tar.gz
ppe42-gcc-fc2ed4c70573a5848c72e7b163671b5c164635ca.zip
2003-10-15 Michael Koch <konqueror@gmx.de>
* java/util/zip/InflaterInputStream.java (InflaterInputStream): Renamed infl to inf and bufsize to size, added description to exception, check for inf == null and size < 0. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72519 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/java')
-rw-r--r--libjava/java/util/zip/InflaterInputStream.java14
1 files changed, 10 insertions, 4 deletions
diff --git a/libjava/java/util/zip/InflaterInputStream.java b/libjava/java/util/zip/InflaterInputStream.java
index 8ee88e5f11c..597ed6bee5b 100644
--- a/libjava/java/util/zip/InflaterInputStream.java
+++ b/libjava/java/util/zip/InflaterInputStream.java
@@ -70,15 +70,21 @@ public class InflaterInputStream extends FilterInputStream
this (in, infl, 512);
}
- public InflaterInputStream (InputStream in, Inflater infl, int bufsize)
+ public InflaterInputStream (InputStream in, Inflater inf, int size)
{
super (in);
if (in == null)
- throw new NullPointerException();
+ throw new NullPointerException ("in may not be null");
+
+ if (inf == null)
+ throw new NullPointerException ("inf may not be null");
+
+ if (size < 0)
+ throw new IllegalArgumentException ("size may not be negative");
- this.inf = infl;
- this.buf = new byte[bufsize];
+ this.inf = inf;
+ this.buf = new byte [size];
}
public int read () throws IOException
OpenPOWER on IntegriCloud