mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-17 08:20:30 +02:00
Some error handling and assert improvements, trying to understand #10662
This commit is contained in:
1 parent
c7dcb7c365
commit
ee752f5399
4 files changed
+27
-15
No files matched your search
+2
-3
@@ -131,8 +131,7 @@ bool ManagedTexture::LoadFromFileData(const uint8_t *data, size_t dataSize, Imag
|
||||
if (image[i])
|
||||
free(image[i]);
|
||||
}
|
||||
|
||||
return true;
|
||||
return texture_ != nullptr;
|
||||
}
|
||||
|
||||
bool ManagedTexture::LoadFromFile(const std::string &filename, ImageFileType type, bool generateMips) {
|
||||
@@ -172,4 +171,4 @@ std::unique_ptr<ManagedTexture> CreateTextureFromFileData(Draw::DrawContext *dra
|
||||
ManagedTexture *mtex = new ManagedTexture(draw);
|
||||
mtex->LoadFromFileData(data, size, type, generateMips);
|
||||
return std::move(std::unique_ptr<ManagedTexture>(mtex));
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user