mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 22:34:27 +02:00
Merge
This commit is contained in:
commit
d9ca438d06
41 changed files with 979 additions and 824 deletions
|
@ -37,7 +37,6 @@ import jdk.internal.vm.annotation.ForceInline;
|
|||
|
||||
import java.io.FileDescriptor;
|
||||
import java.lang.foreign.MemorySegment;
|
||||
import java.lang.foreign.MemorySession;
|
||||
import java.util.Objects;
|
||||
import java.util.Spliterator;
|
||||
|
||||
|
@ -771,11 +770,7 @@ public abstract sealed class Buffer
|
|||
final void checkSession() {
|
||||
MemorySessionImpl session = session();
|
||||
if (session != null) {
|
||||
try {
|
||||
session.checkValidState();
|
||||
} catch (ScopedMemoryAccess.ScopedAccessError e) {
|
||||
throw new IllegalStateException("This segment is already closed");
|
||||
}
|
||||
session.checkValidState();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -313,11 +313,7 @@ class Direct$Type$Buffer$RW$$BO$
|
|||
if (session.ownerThread() == null && session.isCloseable()) {
|
||||
throw new UnsupportedOperationException("ByteBuffer derived from closeable shared sessions not supported");
|
||||
}
|
||||
try {
|
||||
session.checkValidState();
|
||||
} catch (ScopedAccessError e) {
|
||||
throw new IllegalStateException("This segment is already closed");
|
||||
}
|
||||
session.checkValidState();
|
||||
}
|
||||
return address;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue