diff options
| author | Mat M <mathew1800@gmail.com> | 2016-09-17 16:44:25 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-09-17 16:44:25 -0400 |
| commit | 331b112816417dae548b61d8fae21d5e0826d855 (patch) | |
| tree | 8fcec3faba959e53e2759c0a9134470a83708550 /Source/Core/DiscIO/NANDContentLoader.cpp | |
| parent | 22b5d89bf15e22de63264771c1f373519ea5cc25 (diff) | |
| parent | 5aeedcd27c5561508026846a2a746926cd03d20b (diff) | |
Merge pull request #4214 from lioncash/nandcontent
NANDContentLoader: Minor changes
Diffstat (limited to 'Source/Core/DiscIO/NANDContentLoader.cpp')
| -rw-r--r-- | Source/Core/DiscIO/NANDContentLoader.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/Core/DiscIO/NANDContentLoader.cpp b/Source/Core/DiscIO/NANDContentLoader.cpp index 98978d98b0..3f2c746bd6 100644 --- a/Source/Core/DiscIO/NANDContentLoader.cpp +++ b/Source/Core/DiscIO/NANDContentLoader.cpp @@ -107,18 +107,18 @@ void CNANDContentDataFile::Open() { EnsureOpen(); } -const std::vector<u8> CNANDContentDataFile::Get() +std::vector<u8> CNANDContentDataFile::Get() { - std::vector<u8> result; EnsureOpen(); + if (!m_file->IsGood()) - return result; + return {}; u64 size = m_file->GetSize(); if (size == 0) - return result; + return {}; - result.resize(size); + std::vector<u8> result(size); m_file->ReadBytes(result.data(), result.size()); return result; |
