diff options
| author | 2018-07-18 23:16:10 -0400 | |
|---|---|---|
| committer | 2018-07-18 23:19:28 -0400 | |
| commit | 4790bb907db5ff53b8bd62cc93c65fc2749b1fc4 (patch) | |
| tree | e377a85ce1f6e25da0978595420bd7aef91b2dde /src/core/file_sys | |
| parent | content_archive: Add missing standard includes (diff) | |
| download | yuzu-4790bb907db5ff53b8bd62cc93c65fc2749b1fc4.tar.gz yuzu-4790bb907db5ff53b8bd62cc93c65fc2749b1fc4.tar.xz yuzu-4790bb907db5ff53b8bd62cc93c65fc2749b1fc4.zip | |
content_archive: Make IsDirectoryExeFS() take a shared_ptr as a const reference
There's no need to take this by value when it's possible to avoid
unnecessary copies entirely like this.
Diffstat (limited to 'src/core/file_sys')
| -rw-r--r-- | src/core/file_sys/content_archive.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/file_sys/content_archive.h b/src/core/file_sys/content_archive.h index d4517d20e..0b8b9db61 100644 --- a/src/core/file_sys/content_archive.h +++ b/src/core/file_sys/content_archive.h | |||
| @@ -53,7 +53,7 @@ struct NCAHeader { | |||
| 53 | }; | 53 | }; |
| 54 | static_assert(sizeof(NCAHeader) == 0x400, "NCAHeader has incorrect size."); | 54 | static_assert(sizeof(NCAHeader) == 0x400, "NCAHeader has incorrect size."); |
| 55 | 55 | ||
| 56 | inline bool IsDirectoryExeFS(std::shared_ptr<FileSys::VfsDirectory> pfs) { | 56 | inline bool IsDirectoryExeFS(const std::shared_ptr<VfsDirectory>& pfs) { |
| 57 | // According to switchbrew, an exefs must only contain these two files: | 57 | // According to switchbrew, an exefs must only contain these two files: |
| 58 | return pfs->GetFile("main") != nullptr && pfs->GetFile("main.npdm") != nullptr; | 58 | return pfs->GetFile("main") != nullptr && pfs->GetFile("main.npdm") != nullptr; |
| 59 | } | 59 | } |