Code review comment for lp:~gerboland/unity-mir/use-upstart-app-launch2

Daniel d'Andrada (dandrader) wrote :

@@ -428,7 +347,10 @@ void ApplicationManager::authorizeSessio

     QString argStr(;
     QStringList arguments(argStr.split(' '));
- application = new Application(desktopData, pid, stage, Application::Starting, arguments, m_taskController);
+ application = new Application(desktopData->appId(), Application::Starting, arguments, this);
+ delete desktopData;
+ application->setPid(pid);
+ application->setStage(stage);

It's rather wasteful to parse a desktop file twice in this situation. Can't we easily avoid it by having a second constructor that takes a DesktopFileReader instead of a appId as an argument?

« Back to merge proposal