Base64 style points

This commit is contained in:
UnfamiliarLegacy 2024-07-06 01:08:21 +02:00
parent bb7dd9db6e
commit 3a10d6d185
2 changed files with 5 additions and 9 deletions

View File

@ -20,14 +20,10 @@ public class Base64Encoding {
public static int decode(byte[] data) { public static int decode(byte[] data) {
int res = 0; int res = 0;
for (int k = data.length - 1, i = 0; k >= 0; k--, i++) for (byte x : data) {
{ final int byteVal = x - 0x40;
int x = data[k] - 0x40;
if (i > 0){ res = (res << 6) | byteVal;
res += x << (i * 6);
} else {
res += x;
}
} }
return res; return res;

View File

@ -11,7 +11,7 @@
<properties> <properties>
<!-- Version of the application. --> <!-- Version of the application. -->
<revision>1.5.4-beta-5</revision> <revision>1.5.4-beta-6</revision>
<changelist>-SNAPSHOT</changelist> <changelist>-SNAPSHOT</changelist>
<!-- Version for https://github.com/sirjonasxx/G-ExtensionStore to keep compatibility with beta versions. --> <!-- Version for https://github.com/sirjonasxx/G-ExtensionStore to keep compatibility with beta versions. -->
<storeVersion>1.5.3</storeVersion> <storeVersion>1.5.3</storeVersion>