diff options
| author | 2021-04-27 12:05:34 -0400 | |
|---|---|---|
| committer | 2021-04-27 12:48:15 -0400 | |
| commit | 724c19a307f31ce1122fb8047c86d5a126d0860f (patch) | |
| tree | 605b89f42d7897aac46f06add54c34201d9354bd /src/core/loader/nax.cpp | |
| parent | Merge pull request #6246 from lioncash/shadow (diff) | |
| download | yuzu-724c19a307f31ce1122fb8047c86d5a126d0860f.tar.gz yuzu-724c19a307f31ce1122fb8047c86d5a126d0860f.tar.xz yuzu-724c19a307f31ce1122fb8047c86d5a126d0860f.zip | |
loader: Resolve instances of variable shadowing
Eliminates variable shadowing cases across all the loaders to bring us
closer to enabling variable shadowing as an error in core.
Diffstat (limited to 'src/core/loader/nax.cpp')
| -rw-r--r-- | src/core/loader/nax.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/core/loader/nax.cpp b/src/core/loader/nax.cpp index 49028177b..f53c3a72c 100644 --- a/src/core/loader/nax.cpp +++ b/src/core/loader/nax.cpp | |||
| @@ -26,14 +26,14 @@ FileType IdentifyTypeImpl(const FileSys::NAX& nax) { | |||
| 26 | } | 26 | } |
| 27 | } // Anonymous namespace | 27 | } // Anonymous namespace |
| 28 | 28 | ||
| 29 | AppLoader_NAX::AppLoader_NAX(FileSys::VirtualFile file) | 29 | AppLoader_NAX::AppLoader_NAX(FileSys::VirtualFile file_) |
| 30 | : AppLoader(file), nax(std::make_unique<FileSys::NAX>(file)), | 30 | : AppLoader(file_), nax(std::make_unique<FileSys::NAX>(file_)), |
| 31 | nca_loader(std::make_unique<AppLoader_NCA>(nax->GetDecrypted())) {} | 31 | nca_loader(std::make_unique<AppLoader_NCA>(nax->GetDecrypted())) {} |
| 32 | 32 | ||
| 33 | AppLoader_NAX::~AppLoader_NAX() = default; | 33 | AppLoader_NAX::~AppLoader_NAX() = default; |
| 34 | 34 | ||
| 35 | FileType AppLoader_NAX::IdentifyType(const FileSys::VirtualFile& file) { | 35 | FileType AppLoader_NAX::IdentifyType(const FileSys::VirtualFile& nax_file) { |
| 36 | const FileSys::NAX nax(file); | 36 | const FileSys::NAX nax(nax_file); |
| 37 | return IdentifyTypeImpl(nax); | 37 | return IdentifyTypeImpl(nax); |
| 38 | } | 38 | } |
| 39 | 39 | ||
| @@ -41,8 +41,7 @@ FileType AppLoader_NAX::GetFileType() const { | |||
| 41 | return IdentifyTypeImpl(*nax); | 41 | return IdentifyTypeImpl(*nax); |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | AppLoader_NAX::LoadResult AppLoader_NAX::Load(Kernel::Process& process, | 44 | AppLoader_NAX::LoadResult AppLoader_NAX::Load(Kernel::Process& process, Core::System& system) { |
| 45 | [[maybe_unused]] Core::System& system) { | ||
| 46 | if (is_loaded) { | 45 | if (is_loaded) { |
| 47 | return {ResultStatus::ErrorAlreadyLoaded, {}}; | 46 | return {ResultStatus::ErrorAlreadyLoaded, {}}; |
| 48 | } | 47 | } |