瀏覽代碼

Merge pull request #29287 from akien-mga/invalid-encryption-key

FileAccessEncrypted: Be more explicit on decryption failure
Rémi Verschelde 6 年之前
父節點
當前提交
50f4f9d07b
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      core/io/file_access_encrypted.cpp

+ 1 - 0
core/io/file_access_encrypted.cpp

@@ -100,6 +100,7 @@ Error FileAccessEncrypted::open_and_parse(FileAccess *p_base, const Vector<uint8
 		MD5Update(&md5, (uint8_t *)data.ptr(), data.size());
 		MD5Final(&md5);
 
+		ERR_EXPLAIN("The MD5 sum of the decrypted file does not match the expected value. It could be that the file is corrupt, or that the provided decryption key is invalid.");
 		ERR_FAIL_COND_V(String::md5(md5.digest) != String::md5(md5d), ERR_FILE_CORRUPT);
 
 		file = p_base;