Don't swallow the exception on checksum errors.

This commit is contained in:
Maschell 2019-04-14 14:49:47 +02:00
parent 7d8bb58cc4
commit 1698acb3f6

View File

@ -280,7 +280,6 @@ public class NUSDecryption extends AESDecryption {
decryptFileStreamHashed(inputStream, outputStream, size, offset, (short) contentIndex, h3);
} else {
try {
byte[] h3Hash = content.getSHA2Hash();
// We want to check if we read the whole file or just a part of it.
// There should be only one actual file inside a non-hashed content.
@ -290,9 +289,6 @@ public class NUSDecryption extends AESDecryption {
h3Hash = null;
}
decryptFileStream(inputStream, outputStream, size, offset, (short) contentIndex, h3Hash, encryptedFileSize);
} catch (Exception e) {
e.printStackTrace();
}
}
} else {
StreamUtils.saveInputStreamToOutputStreamWithHash(inputStream, outputStream, size, content.getSHA2Hash(), encryptedFileSize);