Skip to content

Commit

Permalink
Fix for crash, from double calling of destructor when MainWindow went…
Browse files Browse the repository at this point in the history
… out of scope
  • Loading branch information
malcom2073 committed Jan 9, 2014
1 parent 29e70a7 commit 9f0f013
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions core/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,10 +142,10 @@ int main(int argc, char *argv[])
}
}

MainWindow w;
MainWindow *w = new MainWindow();
if (port != "")
{
w.setDevice(port);
w->setDevice(port);
}
if (plugin == "")
{
Expand Down Expand Up @@ -179,11 +179,11 @@ int main(int argc, char *argv[])
plugin = "/usr/share/emstudio/plugins/libfreeemsplugin.dylib";
}
}
w.setPlugin(plugin);
w->setPlugin(plugin);
if (autoconnect)
{
w.connectToEms();
w->connectToEms();
}
w.show();
w->show();
return a.exec();
}

0 comments on commit 9f0f013

Please sign in to comment.