mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-30 17:01:08 +02:00
CTestMenu: Fix memleak
Origin commit data
------------------
Commit: c5e0552438
Author: Michael Liebmann <tuxcode.bbg@gmail.com>
Date: 2013-06-06 (Thu, 06 Jun 2013)
This commit is contained in:
@@ -567,8 +567,8 @@ int CTestMenu::exec(CMenuTarget* parent, const std::string &actionKey)
|
|||||||
else if (clock_r->isClockRun()){
|
else if (clock_r->isClockRun()){
|
||||||
if (clock_r->Stop()){
|
if (clock_r->Stop()){
|
||||||
clock_r->hide();
|
clock_r->hide();
|
||||||
delete clock;
|
delete clock_r;
|
||||||
clock = NULL;
|
clock_r = NULL;
|
||||||
return menu_return::RETURN_EXIT_ALL;;
|
return menu_return::RETURN_EXIT_ALL;;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -581,9 +581,11 @@ int CTestMenu::exec(CMenuTarget* parent, const std::string &actionKey)
|
|||||||
|
|
||||||
if (!clock->isPainted())
|
if (!clock->isPainted())
|
||||||
clock->paint();
|
clock->paint();
|
||||||
else
|
else {
|
||||||
clock->hide();
|
clock->hide();
|
||||||
|
delete clock;
|
||||||
|
clock = NULL;
|
||||||
|
}
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user