| 83 | } |
| 84 | |
| 85 | void MinidumpRunControl::start(const QString ¶ms, const QString &target) |
| 86 | { |
| 87 | qDebug() << __FUNCTION__ << ", object:" << this; |
| 88 | |
| 89 | if (target.isEmpty() || !QFile::exists(target)) { |
| 90 | QMessageBox::warning(nullptr, tr("Reverse debug"), tr("Target: %1 not found, recored failed!").arg(target)); |
| 91 | return; |
| 92 | } |
| 93 | |
| 94 | execFile = CustomPaths::global(CustomPaths::Tools) + QDir::separator() + "emd"; |
| 95 | if (!params.isEmpty()) { |
| 96 | execFile += ' ' + params + ' '; |
| 97 | } |
| 98 | execFile += target; // target debuggee |
| 99 | |
| 100 | appendMessage(tr("[Start] %1").arg(execFile) + QLatin1Char('\n')); |
| 101 | |
| 102 | process->start(execFile); |
| 103 | if (!process->waitForStarted(1000)) { |
| 104 | qDebug() << "Failed to run emd"; |
| 105 | return; |
| 106 | } |
| 107 | |
| 108 | kEmdRunning = true; |
| 109 | } |
| 110 | |
| 111 | StopResult MinidumpRunControl::stop() |
| 112 | { |