mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 06:45:07 +02:00
8219876: (bf) Improve IndexOutOfBoundsException messages in $Type$Buffer classes
Reviewed-by: alanb, rriggs
This commit is contained in:
parent
5c5089b0a2
commit
7211761cab
6 changed files with 14 additions and 27 deletions
|
@ -731,11 +731,6 @@ public abstract class Buffer {
|
|||
mark = -1;
|
||||
}
|
||||
|
||||
static void checkBounds(int off, int len, int size) { // package-private
|
||||
if ((off | len | (off + len) | (size - (off + len))) < 0)
|
||||
throw new IndexOutOfBoundsException();
|
||||
}
|
||||
|
||||
static {
|
||||
// setup access to this package in SharedSecrets
|
||||
SharedSecrets.setJavaNioAccess(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue