SF bugzilla 221 - delete cleanup object before returning non NULL createError
authordadubrow
Tue, 11 Aug 2009 13:27:04 -0500
changeset 409 2bdd901b072d
parent 408 019f4256a973
child 414 393919dade6d
SF bugzilla 221 - delete cleanup object before returning non NULL createError
templates/com.nokia.carbide.cpp.templates/templates/projecttemplates/Symbian-EXE/src/Basename.cpp
--- a/templates/com.nokia.carbide.cpp.templates/templates/projecttemplates/Symbian-EXE/src/Basename.cpp	Tue Aug 11 12:09:14 2009 -0500
+++ b/templates/com.nokia.carbide.cpp.templates/templates/projecttemplates/Symbian-EXE/src/Basename.cpp	Tue Aug 11 13:27:04 2009 -0500
@@ -63,7 +63,10 @@
 	// Create output console
 	TRAPD(createError, console = Console::NewL(KTextConsoleTitle, TSize(KConsFullScreen,KConsFullScreen)));
 	if (createError)
+		{
+		delete cleanup;
 		return createError;
+		}
 
 	// Run application code inside TRAP harness, wait keypress when terminated
 	TRAPD(mainError, DoStartL());