1
0
Fork 0
forked from suyu/suyu

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:
Zach Hilman 2018-08-21 15:04:03 -04:00
parent a7e8d10969
commit 119ab308b5
2 changed files with 2 additions and 0 deletions

View file

@ -205,6 +205,7 @@ void KeyManager::WriteKeyToFile(bool title_key, std::string_view keyname,
if (!title_key)
filename = dev_mode ? "dev.keys_autogenerated" : "prod.keys_autogenerated";
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);
if (!file.is_open())
return;

View file

@ -3,6 +3,7 @@
// Refer to the license.txt file included.
#include <memory>
#include "core/file_sys/registered_cache.h"
#include "core/file_sys/sdmc_factory.h"
#include "core/file_sys/xts_archive.h"