Commit ae25be96 authored by Matthias Möller's avatar Matthias Möller
Browse files

fix: possible crash with multiple processes

(row variable wasn't updated, if the job widget row was changed)

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@20233 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 14a4a424
......@@ -157,7 +157,6 @@ void ProcessManagerWidget::addJob(QString _id, QString _description,
// Insert job into local map
JobContainer job;
job.row = newRow;
job.id = name;
job.description = desc;
job.progress = progressBar;
......@@ -197,7 +196,7 @@ void ProcessManagerWidget::removeJob(QString _id) {
// No such item has been found -> returning
if(!found) return;
this->processList->removeRow(job.row);
this->processList->removeRow(this->processList->row(job.id));
// Remove from local map
processMap_.erase(_id);
......
......@@ -118,7 +118,6 @@ class ProcessManagerWidget : public QWidget, public Ui::ProcessManagerWidget
// A container to hold the widget items
struct JobContainer {
int row;
QTableWidgetItem* id;
QTableWidgetItem* description;
QProgressBar* progress;
......
Supports Markdown
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