Commit e13f1a50 authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh

Debugger: Fix memory leaks

Detected by memcheck.

Change-Id: I56c0c39f3aa2251d6425ddc9388fdebc511d7f47
Reviewed-by: default avatarhjk <hjk@theqtcompany.com>
parent 93ef19b2
......@@ -57,7 +57,7 @@ namespace Internal {
Console::Console()
{
m_consoleItemModel = new ConsoleItemModel;
m_consoleItemModel = new ConsoleItemModel(this);
m_consoleWidget = new QWidget;
m_consoleWidget->setWindowTitle(displayName());
......
......@@ -1738,7 +1738,7 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments,
m_modeWindow = createModeWindow(m_mode, m_mainWindow, 0);
m_mode->setWidget(m_modeWindow);
(void) new DebugModeContext(m_mainWindow);
m_plugin->addAutoReleasedObject(new DebugModeContext(m_mainWindow));
m_plugin->addObject(m_mode);
......@@ -3523,7 +3523,7 @@ void registerToolbar(const QByteArray &perspectiveId, const ToolbarDescription &
QAction *createStartAction()
{
auto action = new QAction(DebuggerMainWindow::tr("Start"), 0);
auto action = new QAction(DebuggerMainWindow::tr("Start"), DebuggerPlugin::instance());
action->setIcon(Debugger::Icons::ANALYZER_CONTROL_START.icon());
action->setEnabled(true);
return action;
......@@ -3531,7 +3531,7 @@ QAction *createStartAction()
QAction *createStopAction()
{
auto action = new QAction(DebuggerMainWindow::tr("Stop"), 0);
auto action = new QAction(DebuggerMainWindow::tr("Stop"), DebuggerPlugin::instance());
action->setIcon(ProjectExplorer::Icons::STOP_SMALL.icon());
action->setEnabled(true);
return action;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment