mirror of
https://github.com/fankes/termux-app.git
synced 2025-09-04 09:45:45 +08:00
Fixed: Fix bootstrap checksum check if it contained leading zeros
This commit is contained in:
@@ -177,6 +177,7 @@ def downloadBootstrap(String arch, String expectedChecksum, String version) {
|
||||
out.close()
|
||||
|
||||
def checksum = new BigInteger(1, digest.digest()).toString(16)
|
||||
while (checksum.length() < 64) { checksum = "0" + checksum }
|
||||
if (checksum != expectedChecksum) {
|
||||
file.delete()
|
||||
throw new GradleException("Wrong checksum for " + remoteUrl + ": expected: " + expectedChecksum + ", actual: " + checksum)
|
||||
|
Reference in New Issue
Block a user