diff --git a/Engine.cc b/Engine.cc index 1cffbef..9fb6744 100644 --- a/Engine.cc +++ b/Engine.cc @@ -128,6 +128,12 @@ Engine::~Engine() { delete it->second; } + for (std::map::iterator it = m_texts.begin(); + it != m_texts.end(); + it++) + { + SDL_FreeSurface(it->second); + } delete m_fileLoader; if (m_font != NULL) TTF_CloseFont(m_font);