diff options
| author | 2015-01-06 21:30:40 +0000 | |
|---|---|---|
| committer | 2015-01-15 21:21:26 +0000 | |
| commit | b5237e885df72f6c37532fc8af9573966e7b07e5 (patch) | |
| tree | fdfd4da299cc2779f35fcc30e770b85b9e710166 /src/core/loader/elf.h | |
| parent | Loader: Initialize the default NCCH values in the class declaration, not in t... (diff) | |
| download | yuzu-b5237e885df72f6c37532fc8af9573966e7b07e5.tar.gz yuzu-b5237e885df72f6c37532fc8af9573966e7b07e5.tar.xz yuzu-b5237e885df72f6c37532fc8af9573966e7b07e5.zip | |
Loader: Keep a reference to the file and pass it to the correct AppLoader, instead of loading it multiple times.
Diffstat (limited to 'src/core/loader/elf.h')
| -rw-r--r-- | src/core/loader/elf.h | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/core/loader/elf.h b/src/core/loader/elf.h index 856722f1e..1c476c86b 100644 --- a/src/core/loader/elf.h +++ b/src/core/loader/elf.h | |||
| @@ -15,18 +15,13 @@ namespace Loader { | |||
| 15 | /// Loads an ELF/AXF file | 15 | /// Loads an ELF/AXF file |
| 16 | class AppLoader_ELF final : public AppLoader { | 16 | class AppLoader_ELF final : public AppLoader { |
| 17 | public: | 17 | public: |
| 18 | AppLoader_ELF(const std::string& filename); | 18 | AppLoader_ELF(std::unique_ptr<FileUtil::IOFile>&& file) : AppLoader(std::move(file)) { } |
| 19 | ~AppLoader_ELF() override; | ||
| 20 | 19 | ||
| 21 | /** | 20 | /** |
| 22 | * Load the bootable file | 21 | * Load the bootable file |
| 23 | * @return ResultStatus result of function | 22 | * @return ResultStatus result of function |
| 24 | */ | 23 | */ |
| 25 | ResultStatus Load() override; | 24 | ResultStatus Load() override; |
| 26 | |||
| 27 | private: | ||
| 28 | std::string filename; | ||
| 29 | bool is_loaded = false; | ||
| 30 | }; | 25 | }; |
| 31 | 26 | ||
| 32 | } // namespace Loader | 27 | } // namespace Loader |