7154662: {CRC32, Adler32}.update(byte[] b, int off, int len): undocumented ArrayIndexOutOfBoundsException
To add the throws clause Reviewed-by: alanb, chegar
This commit is contained in:
parent
126c55f2cb
commit
bb69156c80
@ -62,6 +62,11 @@ class Adler32 implements Checksum {
|
||||
|
||||
/**
|
||||
* Updates the checksum with the specified array of bytes.
|
||||
*
|
||||
* @throws ArrayIndexOutOfBoundsException
|
||||
* if {@code off} is negative, or {@code len} is negative,
|
||||
* or {@code off+len} is greater than the length of the
|
||||
* array {@code b}
|
||||
*/
|
||||
public void update(byte[] b, int off, int len) {
|
||||
if (b == null) {
|
||||
|
@ -60,6 +60,11 @@ class CRC32 implements Checksum {
|
||||
|
||||
/**
|
||||
* Updates the CRC-32 checksum with the specified array of bytes.
|
||||
*
|
||||
* @throws ArrayIndexOutOfBoundsException
|
||||
* if {@code off} is negative, or {@code len} is negative,
|
||||
* or {@code off+len} is greater than the length of the
|
||||
* array {@code b}
|
||||
*/
|
||||
public void update(byte[] b, int off, int len) {
|
||||
if (b == null) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user