summaryrefslogtreecommitdiff
path: root/Source/Core/DiscIO/Volume.cpp
diff options
context:
space:
mode:
authorJosJuice <josjuice@gmail.com>2017-05-06 17:45:08 +0200
committerJosJuice <josjuice@gmail.com>2017-05-06 17:45:08 +0200
commit36b9e3dd35a7fb4430d4d95300ce5eb30b4f2d6e (patch)
treeb7acf61a01b9ed81012ad22b22c27eac534ea065 /Source/Core/DiscIO/Volume.cpp
parent2261224980f597135b482c9551622e1d89ecf07e (diff)
Don't duplicate code for getting paths based on title IDs
I've seen the expression (u32)(title_id >> 32), (u32)title_id a few more times in my life than I would've liked to...
Diffstat (limited to 'Source/Core/DiscIO/Volume.cpp')
-rw-r--r--Source/Core/DiscIO/Volume.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/Core/DiscIO/Volume.cpp b/Source/Core/DiscIO/Volume.cpp
index 640b709ffe..ade2bd1eab 100644
--- a/Source/Core/DiscIO/Volume.cpp
+++ b/Source/Core/DiscIO/Volume.cpp
@@ -13,6 +13,7 @@
#include "Common/ColorUtil.h"
#include "Common/CommonTypes.h"
#include "Common/FileUtil.h"
+#include "Common/NandPaths.h"
#include "Common/StringUtil.h"
#include "Common/Swap.h"
@@ -30,9 +31,8 @@ std::vector<u32> IVolume::GetWiiBanner(int* width, int* height, u64 title_id)
*width = 0;
*height = 0;
- std::string file_name = StringFromFormat("%s/title/%08x/%08x/data/banner.bin",
- File::GetUserPath(D_WIIROOT_IDX).c_str(),
- (u32)(title_id >> 32), (u32)title_id);
+ const std::string file_name =
+ Common::GetTitleDataPath(title_id, Common::FROM_CONFIGURED_ROOT) + "banner.bin";
if (!File::Exists(file_name))
return std::vector<u32>();