From 34cbf8abde3d85cd983bd3a647bec9d3edebd491 Mon Sep 17 00:00:00 2001 From: "[CST] Focus" Date: Sat, 5 May 2012 16:20:52 +0400 Subject: [PATCH] gui/themes.cpp fix memleaks when using CMenuForwarder --- src/gui/themes.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui/themes.cpp b/src/gui/themes.cpp index 62200de79..84026eee6 100644 --- a/src/gui/themes.cpp +++ b/src/gui/themes.cpp @@ -154,8 +154,8 @@ int CThemes::Show() readThemes(themes); - CStringInputSMS *nameInput = new CStringInputSMS(LOCALE_COLORTHEMEMENU_NAME, &file_name, 30, NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, "abcdefghijklmnopqrstuvwxyz0123456789- "); - CMenuForwarder *m1 = new CMenuForwarder(LOCALE_COLORTHEMEMENU_SAVE, true , NULL, nameInput, NULL, CRCInput::RC_green, NEUTRINO_ICON_BUTTON_GREEN); + CStringInputSMS nameInput(LOCALE_COLORTHEMEMENU_NAME, &file_name, 30, NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, "abcdefghijklmnopqrstuvwxyz0123456789- "); + CMenuForwarder *m1 = new CMenuForwarder(LOCALE_COLORTHEMEMENU_SAVE, true , NULL, &nameInput, NULL, CRCInput::RC_green, NEUTRINO_ICON_BUTTON_GREEN); // Don't show SAVE if UserDir does'nt exist if ( access(USERDIR, F_OK) != 0 ) { // check for existance