-
Bug
-
Resolution: Done
-
Minor
-
None
-
None
-
False
-
None
-
False
The following exception happens when sending a NioMessage with a read-only ByteBuffer:
java.nio.ReadOnlyBufferException
at java.base/java.nio.ByteBuffer.array(ByteBuffer.java:1507)
at org.jgroups.NioMessage.writePayload(NioMessage.java:203)
at org.jgroups.BaseMessage.writeTo(BaseMessage.java:277)
at org.jgroups.util.Util.writeMessage(Util.java:1427)
To reproduce:
new NioMessage(null, ByteBuffer.allocate(1).asReadOnlyBuffer())
.writePayload(new ByteArrayDataOutputStream());