mirror of
https://github.com/MewoLab/AquaDX.git
synced 2026-02-11 23:17:28 +08:00
[billing] Fix Java 11 incompatibility for real
Attempt was made in commit 15aac7e6 but failed miserably
This commit is contained in:
@@ -73,7 +73,11 @@ public class BillingController {
|
|||||||
ByteBuffer sigbytes = ByteBuffer.allocate(15);
|
ByteBuffer sigbytes = ByteBuffer.allocate(15);
|
||||||
sigbytes.order(ByteOrder.LITTLE_ENDIAN);
|
sigbytes.order(ByteOrder.LITTLE_ENDIAN);
|
||||||
sigbytes.putInt(0, val);
|
sigbytes.putInt(0, val);
|
||||||
sigbytes.put(4, keychipId.getBytes(), 0, keychipId.getBytes().length);
|
|
||||||
|
// JDK 11 compatible version of put(int, byte[])
|
||||||
|
for (int i = 0, j = 4; i < keychipId.getBytes().length; i++, j++) {
|
||||||
|
sigbytes.put(j, keychipId.getBytes()[i]);
|
||||||
|
}
|
||||||
|
|
||||||
Signature sig;
|
Signature sig;
|
||||||
try {
|
try {
|
||||||
|
|||||||
Reference in New Issue
Block a user