summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2018-07-18 23:16:10 -0400
committerLioncash <mathew1800@gmail.com>2018-07-18 23:19:28 -0400
commit4790bb907db5ff53b8bd62cc93c65fc2749b1fc4 (patch)
treee377a85ce1f6e25da0978595420bd7aef91b2dde /src
parent87a9bb392b9cd14c646667e17b638931062a1b73 (diff)
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')
-rw-r--r--src/core/file_sys/content_archive.h2
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 {
};
static_assert(sizeof(NCAHeader) == 0x400, "NCAHeader has incorrect size.");
-inline bool IsDirectoryExeFS(std::shared_ptr<FileSys::VfsDirectory> pfs) {
+inline bool IsDirectoryExeFS(const std::shared_ptr<VfsDirectory>& pfs) {
// According to switchbrew, an exefs must only contain these two files:
return pfs->GetFile("main") != nullptr && pfs->GetFile("main.npdm") != nullptr;
}