diff options
Diffstat (limited to 'src/plugins/perfprofiler')
-rw-r--r-- | src/plugins/perfprofiler/perfconfigwidget.cpp | 4 | ||||
-rw-r--r-- | src/plugins/perfprofiler/perfprofilerruncontrol.cpp | 10 | ||||
-rw-r--r-- | src/plugins/perfprofiler/perftracepointdialog.cpp | 10 |
3 files changed, 9 insertions, 15 deletions
diff --git a/src/plugins/perfprofiler/perfconfigwidget.cpp b/src/plugins/perfprofiler/perfconfigwidget.cpp index 9381f1e147c..d201a08ff0d 100644 --- a/src/plugins/perfprofiler/perfconfigwidget.cpp +++ b/src/plugins/perfprofiler/perfconfigwidget.cpp @@ -174,9 +174,7 @@ void PerfConfigWidget::readTracePoints() messageBox.setStandardButtons(QMessageBox::Yes | QMessageBox::No); if (messageBox.exec() == QMessageBox::Yes) { ProjectExplorer::Runnable runnable; - runnable.executable = Utils::FilePath::fromString("perf"); - runnable.commandLineArguments = QLatin1String("probe -l"); - + runnable.command = {"perf", {"probe", "-l"}}; m_process->start(runnable); useTracePointsButton->setEnabled(false); } diff --git a/src/plugins/perfprofiler/perfprofilerruncontrol.cpp b/src/plugins/perfprofiler/perfprofilerruncontrol.cpp index 48bb6cd4bcc..c032edde375 100644 --- a/src/plugins/perfprofiler/perfprofilerruncontrol.cpp +++ b/src/plugins/perfprofiler/perfprofilerruncontrol.cpp @@ -150,13 +150,11 @@ public: QStringList arguments; arguments << "record"; arguments += m_perfRecordArguments; - arguments << "-o" << "-" << "--" << perfRunnable.executable.toString() - << Utils::ProcessArgs::splitArgs(perfRunnable.commandLineArguments, - Utils::OsTypeLinux); + arguments << "-o" << "-" << "--" << perfRunnable.command.executable().toString() + << ProcessArgs::splitArgs(perfRunnable.command.arguments(), OsTypeLinux); - perfRunnable.executable = FilePath::fromString("perf"); - perfRunnable.commandLineArguments = Utils::ProcessArgs::joinArgs(arguments, - Utils::OsTypeLinux); + perfRunnable.command.setExecutable(FilePath::fromString("perf")); + perfRunnable.command.setArguments(ProcessArgs::joinArgs(arguments, OsTypeLinux)); m_process->start(perfRunnable); } diff --git a/src/plugins/perfprofiler/perftracepointdialog.cpp b/src/plugins/perfprofiler/perftracepointdialog.cpp index 771471b186f..ec6f5ba1462 100644 --- a/src/plugins/perfprofiler/perftracepointdialog.cpp +++ b/src/plugins/perfprofiler/perftracepointdialog.cpp @@ -101,12 +101,10 @@ void PerfTracePointDialog::runScript() Runnable runnable; const QString elevate = m_ui->privilegesChooser->currentText(); - if (elevate != QLatin1String("n.a.")) { - runnable.executable = Utils::FilePath::fromString(elevate); - runnable.commandLineArguments = "sh"; - } else { - runnable.executable = Utils::FilePath::fromString("sh"); - } + if (elevate != QLatin1String("n.a.")) + runnable.command = {elevate, {"sh"}}; + else + runnable.command = {"sh", {}}; connect(m_process.get(), &DeviceProcess::started, this, &PerfTracePointDialog::feedScriptToProcess); |