Fix further memory leaks

This commit is contained in:
Henrik Rydgård 2018-02-04 13:38:58 +01:00
parent 79d1610148
commit 020eb9d86c
3 changed files with 5 additions and 0 deletions

View File

@ -913,5 +913,6 @@ int main(int argc, char *argv[]) {
#endif
glslang::FinalizeProcess();
ILOG("Leaving main");
return 0;
}

View File

@ -56,6 +56,9 @@ GLRenderManager::~GLRenderManager() {
for (int i = 0; i < MAX_INFLIGHT_FRAMES; i++) {
_assert_(frameData_[i].deleter.IsEmpty());
}
// Was anything deleted during shutdown?
deleter_.Perform();
// _assert_(deleter_.IsEmpty());
if (!useThread_) {
// The main thread is also the render thread.

View File

@ -297,6 +297,7 @@ public:
OpenGLPipeline(GLRenderManager *render) : render_(render) {
}
~OpenGLPipeline() {
ILOG("OpenGLPipeline released");
for (auto &iter : shaders) {
iter->Release();
}