mirror of
https://github.com/yuzu-mirror/yuzu.git
synced 2024-11-08 07:59:59 +00:00
Fixes Unicode Key File Directories (#2120)
* Fixes Unicode Key File Directories Adds code so that when loading a file it converts to UTF16 first, to ensure the files can be opened. Code borrowed from FileUtil::Exists. * Update src/core/crypto/key_manager.cpp Co-Authored-By: Jungorend <Jungorend@users.noreply.github.com> * Update src/core/crypto/key_manager.cpp Co-Authored-By: Jungorend <Jungorend@users.noreply.github.com> * Using FileUtil instead to be cleaner. * Update src/core/crypto/key_manager.cpp Co-Authored-By: Jungorend <Jungorend@users.noreply.github.com>
This commit is contained in:
parent
ef559f5741
commit
3273f93cd5
1 changed files with 2 additions and 1 deletions
|
@ -398,7 +398,8 @@ static bool ValidCryptoRevisionString(std::string_view base, size_t begin, size_
|
||||||
}
|
}
|
||||||
|
|
||||||
void KeyManager::LoadFromFile(const std::string& filename, bool is_title_keys) {
|
void KeyManager::LoadFromFile(const std::string& filename, bool is_title_keys) {
|
||||||
std::ifstream file(filename);
|
std::ifstream file;
|
||||||
|
OpenFStream(file, filename, std::ios_base::in);
|
||||||
if (!file.is_open())
|
if (!file.is_open())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue