From 8a402f0538b324b28d812c53e879dfd38f67e06f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8C=83=E5=A4=A7=E5=BE=B7?= Date: Tue, 24 Oct 2023 21:53:09 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E7=90=86bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/android/com/cescit/integrity/BaseIntegrity.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/android/com/cescit/integrity/BaseIntegrity.java b/src/android/com/cescit/integrity/BaseIntegrity.java index af78e9b..31734b3 100644 --- a/src/android/com/cescit/integrity/BaseIntegrity.java +++ b/src/android/com/cescit/integrity/BaseIntegrity.java @@ -96,8 +96,7 @@ class BaseIntegrity { byte[] buffer = new byte[1024]; // The buffer to read the file MessageDigest digest = MessageDigest.getInstance(MESSAGE_DIGEST_ALGORITHM); int numRead = 0; // Record how many bytes have been read - digest.digest(bytes); - byte [] sha1Bytes = digest.digest(); + byte [] sha1Bytes = digest.digest(bytes); StringBuffer hexString = new StringBuffer(); for (int i = 0; i < sha1Bytes.length; i++) { hexString.append(Integer.toString(( sha1Bytes[i] & 0xff) + 0x100, 16).substring(1));