summaryrefslogtreecommitdiff
path: root/src/core/loader
diff options
context:
space:
mode:
authorGravatar Emmanuel Gil Peyrot2014-09-12 00:17:15 +0200
committerGravatar Emmanuel Gil Peyrot2014-09-17 14:35:45 +0000
commit6b7b36a8745ddfd0e24fa51ef74dbc3058b3dacc (patch)
treedd5cdcd8b1f9822a019362b44a44ec9505adff8a /src/core/loader
parentCommon: Return the number of items read/written in IOFile’s methods instead... (diff)
downloadyuzu-6b7b36a8745ddfd0e24fa51ef74dbc3058b3dacc.tar.gz
yuzu-6b7b36a8745ddfd0e24fa51ef74dbc3058b3dacc.tar.xz
yuzu-6b7b36a8745ddfd0e24fa51ef74dbc3058b3dacc.zip
Common: Rename the File namespace to FileUtil, to match the filename and prevent collisions.
Diffstat (limited to 'src/core/loader')
-rw-r--r--src/core/loader/elf.cpp2
-rw-r--r--src/core/loader/loader.cpp2
-rw-r--r--src/core/loader/ncch.cpp6
3 files changed, 5 insertions, 5 deletions
diff --git a/src/core/loader/elf.cpp b/src/core/loader/elf.cpp
index 76c9d6d54..389d5a8c9 100644
--- a/src/core/loader/elf.cpp
+++ b/src/core/loader/elf.cpp
@@ -351,7 +351,7 @@ ResultStatus AppLoader_ELF::Load() {
351 if (is_loaded) 351 if (is_loaded)
352 return ResultStatus::ErrorAlreadyLoaded; 352 return ResultStatus::ErrorAlreadyLoaded;
353 353
354 File::IOFile file(filename, "rb"); 354 FileUtil::IOFile file(filename, "rb");
355 355
356 if (file.IsOpen()) { 356 if (file.IsOpen()) {
357 u32 size = (u32)file.GetSize(); 357 u32 size = (u32)file.GetSize();
diff --git a/src/core/loader/loader.cpp b/src/core/loader/loader.cpp
index 577a2297a..a268e021a 100644
--- a/src/core/loader/loader.cpp
+++ b/src/core/loader/loader.cpp
@@ -78,7 +78,7 @@ ResultStatus LoadFile(const std::string& filename) {
78 { 78 {
79 INFO_LOG(LOADER, "Loading BIN file %s...", filename.c_str()); 79 INFO_LOG(LOADER, "Loading BIN file %s...", filename.c_str());
80 80
81 File::IOFile file(filename, "rb"); 81 FileUtil::IOFile file(filename, "rb");
82 82
83 if (file.IsOpen()) { 83 if (file.IsOpen()) {
84 file.ReadBytes(Memory::GetPointer(Memory::EXEFS_CODE_VADDR), (size_t)file.GetSize()); 84 file.ReadBytes(Memory::GetPointer(Memory::EXEFS_CODE_VADDR), (size_t)file.GetSize());
diff --git a/src/core/loader/ncch.cpp b/src/core/loader/ncch.cpp
index 9af59e419..1e5501e6d 100644
--- a/src/core/loader/ncch.cpp
+++ b/src/core/loader/ncch.cpp
@@ -138,7 +138,7 @@ ResultStatus AppLoader_NCCH::LoadExec() const {
138 */ 138 */
139ResultStatus AppLoader_NCCH::LoadSectionExeFS(const char* name, std::vector<u8>& buffer) const { 139ResultStatus AppLoader_NCCH::LoadSectionExeFS(const char* name, std::vector<u8>& buffer) const {
140 // Iterate through the ExeFs archive until we find the .code file... 140 // Iterate through the ExeFs archive until we find the .code file...
141 File::IOFile file(filename, "rb"); 141 FileUtil::IOFile file(filename, "rb");
142 if (file.IsOpen()) { 142 if (file.IsOpen()) {
143 for (int i = 0; i < kMaxSections; i++) { 143 for (int i = 0; i < kMaxSections; i++) {
144 // Load the specified section... 144 // Load the specified section...
@@ -199,7 +199,7 @@ ResultStatus AppLoader_NCCH::Load() {
199 if (is_loaded) 199 if (is_loaded)
200 return ResultStatus::ErrorAlreadyLoaded; 200 return ResultStatus::ErrorAlreadyLoaded;
201 201
202 File::IOFile file(filename, "rb"); 202 FileUtil::IOFile file(filename, "rb");
203 if (file.IsOpen()) { 203 if (file.IsOpen()) {
204 file.ReadBytes(&ncch_header, sizeof(NCCH_Header)); 204 file.ReadBytes(&ncch_header, sizeof(NCCH_Header));
205 205
@@ -290,7 +290,7 @@ ResultStatus AppLoader_NCCH::ReadLogo(std::vector<u8>& buffer) const {
290 * @return ResultStatus result of function 290 * @return ResultStatus result of function
291 */ 291 */
292ResultStatus AppLoader_NCCH::ReadRomFS(std::vector<u8>& buffer) const { 292ResultStatus AppLoader_NCCH::ReadRomFS(std::vector<u8>& buffer) const {
293 File::IOFile file(filename, "rb"); 293 FileUtil::IOFile file(filename, "rb");
294 if (file.IsOpen()) { 294 if (file.IsOpen()) {
295 // Check if the NCCH has a RomFS... 295 // Check if the NCCH has a RomFS...
296 if (ncch_header.romfs_offset != 0 && ncch_header.romfs_size != 0) { 296 if (ncch_header.romfs_offset != 0 && ncch_header.romfs_size != 0) {