key_manager: Create keys dir if it dosen't exist
On call to WriteKeyToFile, so that the autogenerated file can be written.
This commit is contained in:
parent
a7e8d10969
commit
119ab308b5
2 changed files with 2 additions and 0 deletions
|
@ -205,6 +205,7 @@ void KeyManager::WriteKeyToFile(bool title_key, std::string_view keyname,
|
||||||
if (!title_key)
|
if (!title_key)
|
||||||
filename = dev_mode ? "dev.keys_autogenerated" : "prod.keys_autogenerated";
|
filename = dev_mode ? "dev.keys_autogenerated" : "prod.keys_autogenerated";
|
||||||
const auto add_info_text = !FileUtil::Exists(yuzu_keys_dir + DIR_SEP + filename);
|
const auto add_info_text = !FileUtil::Exists(yuzu_keys_dir + DIR_SEP + filename);
|
||||||
|
FileUtil::CreateFullPath(yuzu_keys_dir + DIR_SEP + filename);
|
||||||
std::ofstream file(yuzu_keys_dir + DIR_SEP + filename, std::ios::app);
|
std::ofstream file(yuzu_keys_dir + DIR_SEP + filename, std::ios::app);
|
||||||
if (!file.is_open())
|
if (!file.is_open())
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
// Refer to the license.txt file included.
|
// Refer to the license.txt file included.
|
||||||
|
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
#include "core/file_sys/registered_cache.h"
|
||||||
#include "core/file_sys/sdmc_factory.h"
|
#include "core/file_sys/sdmc_factory.h"
|
||||||
#include "core/file_sys/xts_archive.h"
|
#include "core/file_sys/xts_archive.h"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue