From 150527ec194107f0ba5ea9bdef487782e64090ef Mon Sep 17 00:00:00 2001 From: Zach Hilman Date: Sun, 29 Jul 2018 18:42:04 -0400 Subject: Allow key loading from %YUZU_DIR%/keys in addition to ~/.switch --- src/common/common_paths.h | 1 + src/common/file_util.cpp | 1 + src/common/file_util.h | 1 + 3 files changed, 3 insertions(+) (limited to 'src/common') diff --git a/src/common/common_paths.h b/src/common/common_paths.h index 6799a357a..df2ce80b1 100644 --- a/src/common/common_paths.h +++ b/src/common/common_paths.h @@ -32,6 +32,7 @@ #define SDMC_DIR "sdmc" #define NAND_DIR "nand" #define SYSDATA_DIR "sysdata" +#define KEYS_DIR "keys" #define LOG_DIR "log" // Filenames diff --git a/src/common/file_util.cpp b/src/common/file_util.cpp index ed38c3ced..7aeda737f 100644 --- a/src/common/file_util.cpp +++ b/src/common/file_util.cpp @@ -706,6 +706,7 @@ const std::string& GetUserPath(UserPath path, const std::string& new_path) { paths.emplace(UserPath::SDMCDir, user_path + SDMC_DIR DIR_SEP); paths.emplace(UserPath::NANDDir, user_path + NAND_DIR DIR_SEP); paths.emplace(UserPath::SysDataDir, user_path + SYSDATA_DIR DIR_SEP); + paths.emplace(UserPath::KeysDir, user_path + KEYS_DIR DIR_SEP); // TODO: Put the logs in a better location for each OS paths.emplace(UserPath::LogDir, user_path + LOG_DIR DIR_SEP); } diff --git a/src/common/file_util.h b/src/common/file_util.h index d530d86c9..28697d527 100644 --- a/src/common/file_util.h +++ b/src/common/file_util.h @@ -23,6 +23,7 @@ namespace FileUtil { enum class UserPath { CacheDir, ConfigDir, + KeysDir, LogDir, NANDDir, RootDir, -- cgit v1.2.3