From a7f1e788e6f9fb4e9d84f2975f6691ea976c052b Mon Sep 17 00:00:00 2001 From: Eladash Date: Fri, 4 Jun 2021 21:06:04 +0300 Subject: [PATCH] Fix missing game licence logging (#10402) --- rpcs3/Emu/system_utils.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/rpcs3/Emu/system_utils.cpp b/rpcs3/Emu/system_utils.cpp index 1f693a6129..398507e2d5 100644 --- a/rpcs3/Emu/system_utils.cpp +++ b/rpcs3/Emu/system_utils.cpp @@ -136,11 +136,13 @@ namespace rpcs3::utils { const std::string home_dir = get_hdd0_dir() + "/home"; + std::string rap_path; + for (auto&& entry : fs::dir(home_dir)) { if (entry.is_directory && check_user(entry.name)) { - std::string rap_path = fmt::format("%s/%s/exdata/%s.rap", home_dir, entry.name, rap); + rap_path = fmt::format("%s/%s/exdata/%s.rap", home_dir, entry.name, rap); if (fs::is_file(rap_path)) { return rap_path; @@ -148,7 +150,8 @@ namespace rpcs3::utils } } - return {}; + // Return a sample path tested for logging purposes + return rap_path; } std::string get_sfo_dir_from_game_path(const std::string& game_path, const std::string& title_id)