diff options
author | Andrei Karas <akaras@inbox.ru> | 2018-11-12 00:37:13 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2018-11-12 02:02:30 +0300 |
commit | 6f9db38b7fdd7f5bfccf0a53b348db3a76d5851b (patch) | |
tree | 2f7bd13b86a7be215c7fac5d5bbd5f0c8d82879a | |
parent | caa6802392ef5bd400d080d3d7778e19f815074c (diff) | |
download | plus-6f9db38b7fdd7f5bfccf0a53b348db3a76d5851b.tar.gz plus-6f9db38b7fdd7f5bfccf0a53b348db3a76d5851b.tar.bz2 plus-6f9db38b7fdd7f5bfccf0a53b348db3a76d5851b.tar.xz plus-6f9db38b7fdd7f5bfccf0a53b348db3a76d5851b.zip |
Fix memory leak in dyecmd on exit.
-rw-r--r-- | src/progs/dyecmd/dyemain.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/progs/dyecmd/dyemain.cpp b/src/progs/dyecmd/dyemain.cpp index 310ee04a7..6de3ef2fe 100644 --- a/src/progs/dyecmd/dyemain.cpp +++ b/src/progs/dyecmd/dyemain.cpp @@ -36,6 +36,8 @@ #include "resources/loaders/imageloader.h" +#include "resources/resourcemanager/resourcemanager.h" + #include "utils/cpu.h" #include "utils/gettext.h" #include "utils/pnglib.h" @@ -120,6 +122,8 @@ int main(int argc, char **argv) image->getSDLSurface()); PngLib::writePNG(surface, dst); SDL_FreeSurface(surface); + image->decRef(); + ResourceManager::cleanOrphans(true); VirtFs::deinit(); return 0; } |