mirror of
https://github.com/corda/corda.git
synced 2025-06-17 06:38:21 +00:00
Fix ByteBuffer bugs
This commit is contained in:
@ -60,6 +60,7 @@ public class ByteBuffer {
|
|||||||
if (position != 0) {
|
if (position != 0) {
|
||||||
System.arraycopy(array, arrayOffset+position, array, arrayOffset, remaining());
|
System.arraycopy(array, arrayOffset+position, array, arrayOffset, remaining());
|
||||||
}
|
}
|
||||||
|
position=0;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -74,7 +75,7 @@ public class ByteBuffer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public ByteBuffer put(byte val) {
|
public ByteBuffer put(byte val) {
|
||||||
array[position++] = val;
|
array[arrayOffset+(position++)] = val;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user